diff options
author | KunMing Xie <qqzz014@gmail.com> | 2017-09-18 02:04:17 +0800 |
---|---|---|
committer | Justin M. Keyes <justinkz@gmail.com> | 2017-09-17 20:04:17 +0200 |
commit | cf59d617bc6d2aabb487c4d6be8082160a633a39 (patch) | |
tree | 25a98a8730e212c6134869a945a4b9a41b1a40a9 /src/nvim/testdir | |
parent | 009c695f0a6c6da322f89e0f621d59d596e712fa (diff) | |
download | rneovim-cf59d617bc6d2aabb487c4d6be8082160a633a39.tar.gz rneovim-cf59d617bc6d2aabb487c4d6be8082160a633a39.tar.bz2 rneovim-cf59d617bc6d2aabb487c4d6be8082160a633a39.zip |
vim-patch:8.0.0324 (#7279)
Problem: Illegal memory access with "1;y".
Solution: Call check_cursor() instead of check_cursor_lnum(). (Dominique
Pelle, closes vim/vim#1455)
https://github.com/vim/vim/commit/f1f6f3f7df2938b3583e341482d96c1d53124c51
Diffstat (limited to 'src/nvim/testdir')
-rw-r--r-- | src/nvim/testdir/test_cmdline.vim | 14 |
1 files changed, 13 insertions, 1 deletions
diff --git a/src/nvim/testdir/test_cmdline.vim b/src/nvim/testdir/test_cmdline.vim index 2facffb067..c0f04f4730 100644 --- a/src/nvim/testdir/test_cmdline.vim +++ b/src/nvim/testdir/test_cmdline.vim @@ -250,9 +250,21 @@ func Test_remove_char_in_cmdline() call assert_equal('"def', @:) endfunc -func Test_illegal_address() +func Test_illegal_address1() new 2;'( 2;') quit endfunc + +func Test_illegal_address2() + call writefile(['c', 'x', ' x', '.', '1;y'], 'Xtest.vim') + new + source Xtest.vim + " Trigger calling validate_cursor() + diffsp Xtest.vim + quit! + bwipe! + call delete('Xtest.vim') +endfunc + |