Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

lint: escape directory for shell invocation #862

Merged
merged 2 commits into from
May 21, 2016
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion autoload/go/lint.vim
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@ endif

function! go#lint#Gometa(autosave, ...) abort
if a:0 == 0
let goargs = expand('%:p:h')
let goargs = shellescape(expand('%:p:h'))
else
let goargs = go#util#Shelljoin(a:000)
endif
Expand Down
4 changes: 2 additions & 2 deletions autoload/go/textobj.vim
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ endif
function! go#textobj#Function(mode)
let offset = go#util#OffsetCursor()

let fname = expand("%:p")
let fname = shellescape(expand("%:p"))
if &modified
" Write current unsaved buffer to a temp file and use the modified content
let l:tmpname = tempname()
Expand Down Expand Up @@ -103,7 +103,7 @@ function! go#textobj#FunctionJump(mode, direction)

let offset = go#util#OffsetCursor()

let fname = expand("%:p")
let fname = shellescape(expand("%:p"))
if &modified
" Write current unsaved buffer to a temp file and use the modified content
let l:tmpname = tempname()
Expand Down