vim-patch:8.2.4901: NULL pointer access when using invalid pattern

Problem:    NULL pointer access when using invalid pattern.
Solution:   Check for failed regexp program.
8e4b76da1d
This commit is contained in:
zeertzjq
2022-05-11 19:07:31 +08:00
parent 96a125b207
commit 0019886a84
2 changed files with 8 additions and 1 deletions

View File

@@ -61,4 +61,11 @@ func Test_buffer_scheme()
set shellslash&
endfunc
" this was using a NULL pointer after failing to use the pattern
func Test_buf_pattern_invalid()
vsplit 0000000
silent! buf [0--]\&\zs*\zs*e
bwipe!
endfunc
" vim: shiftwidth=2 sts=2 expandtab