Skip to content

Commit

Permalink
Check to make sure our buffer is still there
Browse files Browse the repository at this point in the history
Some autocmds might have deleted it already.

Fix fholgado#90.
  • Loading branch information
weynhamz committed Jun 20, 2013
1 parent 33f5a88 commit bfc56c3
Showing 1 changed file with 6 additions and 0 deletions.
6 changes: 6 additions & 0 deletions plugin/minibufexpl.vim
Original file line number Diff line number Diff line change
Expand Up @@ -469,6 +469,12 @@ endfunction
function! <SID>BufAddHandler()
call <SID>DEBUG('Entering BufAdd Handler', 10)

" Check to make sure our buffer is still there, some autocmds
" might have deleted it already.
if !bufexists(expand("<abuf"))
return
endif

call <SID>ListAdd(s:BufList,str2nr(expand("<abuf>")))
call <SID>ListAdd(s:MRUList,str2nr(expand("<abuf>")))

Expand Down

0 comments on commit bfc56c3

Please sign in to comment.