Workaround: make syntastic#util#fname2buf() less broken.
This commit is contained in:
parent
8102624901
commit
0e3b6b6271
@ -307,8 +307,12 @@ function! syntastic#util#fname2buf(fname) abort " {{{2
|
||||
|
||||
" this is a best-effort attempt to escape file patterns (cf. :h file-pattern)
|
||||
" XXX it fails for filenames containing something like \{2,3}
|
||||
let buf = -1
|
||||
for md in [':~:.', ':~', ':p']
|
||||
let buf = bufnr('^' . escape(fnamemodify(a:fname, md), '\*?,{}[') . '$')
|
||||
try
|
||||
" Older versions of Vim can throw E94 here
|
||||
let buf = bufnr('^' . escape(fnamemodify(a:fname, md), '\*?,{}[') . '$')
|
||||
endtry
|
||||
if buf != -1
|
||||
break
|
||||
endif
|
||||
|
@ -19,7 +19,7 @@ if has('reltime')
|
||||
lockvar! g:_SYNTASTIC_START
|
||||
endif
|
||||
|
||||
let g:_SYNTASTIC_VERSION = '3.8.0-92'
|
||||
let g:_SYNTASTIC_VERSION = '3.8.0-93'
|
||||
lockvar g:_SYNTASTIC_VERSION
|
||||
|
||||
" Sanity checks {{{1
|
||||
|
Loading…
Reference in New Issue
Block a user