aboutsummaryrefslogtreecommitdiff
path: root/src/nvim/testdir
diff options
context:
space:
mode:
authorChristian Clason <c.clason@uni-graz.at>2022-01-26 16:37:25 +0100
committerChristian Clason <c.clason@uni-graz.at>2022-01-26 22:00:29 +0100
commitb2b288f33c7a8e780654d5f883dfc2948ff7edc3 (patch)
tree5b2c5c5b6d92aac0053b09976fb2bc87d8c927aa /src/nvim/testdir
parentde673966c3b681e8354a26a1f054fbda6e07294a (diff)
downloadrneovim-b2b288f33c7a8e780654d5f883dfc2948ff7edc3.tar.gz
rneovim-b2b288f33c7a8e780654d5f883dfc2948ff7edc3.tar.bz2
rneovim-b2b288f33c7a8e780654d5f883dfc2948ff7edc3.zip
vim-patch:8.2.4215: illegal memory access when copying lines in Visual mode
Problem: Illegal memory access when copying lines in Visual mode. Solution: Adjust the Visual position after copying lines. https://github.com/vim/vim/commit/dc5490e2cbc8c16022a23b449b48c1bd0083f366
Diffstat (limited to 'src/nvim/testdir')
-rw-r--r--src/nvim/testdir/test_visual.vim11
1 files changed, 11 insertions, 0 deletions
diff --git a/src/nvim/testdir/test_visual.vim b/src/nvim/testdir/test_visual.vim
index e1e7765e06..5fb4934a1d 100644
--- a/src/nvim/testdir/test_visual.vim
+++ b/src/nvim/testdir/test_visual.vim
@@ -1151,5 +1151,16 @@ func Test_visual_reselect_with_count()
call delete('XvisualReselect')
endfunc
+" this was leaving the end of the Visual area beyond the end of a line
+func Test_visual_ex_copy_line()
+ new
+ call setline(1, ["aaa", "bbbbbbbbbxbb"])
+ /x
+ exe "normal ggvjfxO"
+ t0
+ normal gNU
+ bwipe!
+endfunc
+
" vim: shiftwidth=2 sts=2 expandtab