async: fnameescape filename
A buffer name wich special characters such as Command-T [Files] will cause E94 when trying to call setbufvar() on it. That is because the '[]' is special in buffer names. Therefore, fnameescape the buffer name. This should prevent 'E94: No matching buffer for /home/louis/git/minivimrc/Command-T [Files]' errors. closes #1906
This commit is contained in:
parent
1297773a26
commit
11cd15d218
|
@ -67,9 +67,9 @@ endfunction
|
|||
function! s:on_exit_clean(...) dict abort
|
||||
let buf=self.buf
|
||||
if !empty(buf)
|
||||
let var=getbufvar(self.file, 'buffer_vcs_config', {})
|
||||
let var=getbufvar(fnameescape(self.file), 'buffer_vcs_config', {})
|
||||
let var[self.vcs].dirty=1
|
||||
call setbufvar(self.file, 'buffer_vcs_config', var)
|
||||
call setbufvar(fnameescape(self.file), 'buffer_vcs_config', var)
|
||||
unlet! b:airline_head
|
||||
endif
|
||||
if has_key(get(s:clean_jobs, 'self.vcs', {}), self.file)
|
||||
|
|
Loading…
Reference in New Issue