diff options
author | Bram Moolenaar <Bram@vim.org> | 2022-02-01 13:54:17 +0000 |
---|---|---|
committer | Bram Moolenaar <Bram@vim.org> | 2022-02-01 13:54:17 +0000 |
commit | 9b4a80a66544f2782040b641498754bcb5b8d461 (patch) | |
tree | 5b51ffffb1d60cbd8e771722fc609826526b590a /src/testdir/test_quickfix.vim | |
parent | eb4a9ba293be51039e57e0e18337785e2ce526e7 (diff) | |
download | vim-git-9b4a80a66544f2782040b641498754bcb5b8d461.tar.gz |
patch 8.2.4281: using freed memory with :lopen and :bwipev8.2.4281
Problem: Using freed memory with :lopen and :bwipe.
Solution: Do not use a wiped out buffer.
Diffstat (limited to 'src/testdir/test_quickfix.vim')
-rw-r--r-- | src/testdir/test_quickfix.vim | 17 |
1 files changed, 17 insertions, 0 deletions
diff --git a/src/testdir/test_quickfix.vim b/src/testdir/test_quickfix.vim index fb6d21fc5..07fdb9644 100644 --- a/src/testdir/test_quickfix.vim +++ b/src/testdir/test_quickfix.vim @@ -979,6 +979,7 @@ func Test_locationlist_curwin_was_closed() call assert_fails('lrewind', 'E924:') augroup! testgroup + delfunc R endfunc func Test_locationlist_cross_tab_jump() @@ -5835,4 +5836,20 @@ func Test_two_qf_windows() %bw! endfunc +" Weird sequence of commands that caused entering a wiped-out buffer +func Test_lopen_bwipe() + func R() + silent! tab lopen + e x + silent! lfile + endfunc + + cal R() + cal R() + cal R() + bw! + delfunc R +endfunc + + " vim: shiftwidth=2 sts=2 expandtab |