aboutsummaryrefslogtreecommitdiff
path: root/test
diff options
context:
space:
mode:
authorzeertzjq <zeertzjq@outlook.com>2024-04-24 19:52:01 +0800
committerzeertzjq <zeertzjq@outlook.com>2025-02-28 18:21:08 +0800
commit4e25b1a675976ed238752d547dc05aaaef38af29 (patch)
treed4fe94242977ede190366d550c7791f21a0f1c92 /test
parent7c6a9c55890f77fc7b571de649c232d70db3a01a (diff)
downloadrneovim-4e25b1a675976ed238752d547dc05aaaef38af29.tar.gz
rneovim-4e25b1a675976ed238752d547dc05aaaef38af29.tar.bz2
rneovim-4e25b1a675976ed238752d547dc05aaaef38af29.zip
vim-patch:8.2.4647: "source" can read past end of copied line
Problem: "source" can read past end of copied line. Solution: Add a terminating NUL. https://github.com/vim/vim/commit/2bdad6126778f907c0b98002bfebf0e611a3f5db Co-authored-by: Bram Moolenaar <Bram@vim.org>
Diffstat (limited to 'test')
-rw-r--r--test/old/testdir/test_source.vim9
1 files changed, 9 insertions, 0 deletions
diff --git a/test/old/testdir/test_source.vim b/test/old/testdir/test_source.vim
index 026a4bb5ee..a8111eb03d 100644
--- a/test/old/testdir/test_source.vim
+++ b/test/old/testdir/test_source.vim
@@ -638,4 +638,13 @@ func Test_source_buffer_vim9()
%bw!
endfunc
+func Test_source_buffer_long_line()
+ " This was reading past the end of the line.
+ new
+ norm300gr0
+ so
+ bwipe!
+endfunc
+
+
" vim: shiftwidth=2 sts=2 expandtab