0
0
mirror of https://github.com/vim/vim.git synced 2025-10-14 07:04:10 -04:00

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.
This commit is contained in:
Bram Moolenaar
2022-01-25 13:52:53 +00:00
parent 85b6747abc
commit dc5490e2cb
3 changed files with 15 additions and 0 deletions

View File

@@ -1328,5 +1328,16 @@ func Test_visual_exchange_windows()
bwipe!
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