diff options
author | zeertzjq <zeertzjq@outlook.com> | 2023-04-28 00:01:22 +0800 |
---|---|---|
committer | GitHub <noreply@github.com> | 2023-04-28 00:01:22 +0800 |
commit | 9f29176033926b81553985deaba0ea162ca40215 (patch) | |
tree | 757eb1c1ceb3b34bd63f27bb60adf5b3ecce8c96 /test | |
parent | a3dfe1bc89a518442503189ca074ee8ab4b8b0d4 (diff) | |
download | rneovim-9f29176033926b81553985deaba0ea162ca40215.tar.gz rneovim-9f29176033926b81553985deaba0ea162ca40215.tar.bz2 rneovim-9f29176033926b81553985deaba0ea162ca40215.zip |
vim-patch:9.0.1492: using uninitialized memory when argument is missing (#23351)
Problem: Using uninitialized memory when argument is missing.
Solution: Check there are sufficient arguments before the base.
(closes vim/vim#12302)
https://github.com/vim/vim/commit/b7f2270bab102d68f83a6300699b7f98efad81f2
Co-authored-by: Bram Moolenaar <Bram@vim.org>
Diffstat (limited to 'test')
-rw-r--r-- | test/old/testdir/test_expr.vim | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/test/old/testdir/test_expr.vim b/test/old/testdir/test_expr.vim index ff3dfb83cb..fe79145fc9 100644 --- a/test/old/testdir/test_expr.vim +++ b/test/old/testdir/test_expr.vim @@ -407,6 +407,9 @@ func Test_printf_misc() call CheckLegacyAndVim9Success(lines) call CheckLegacyAndVim9Failure(["call printf('123', 3)"], "E767:") + + " this was using uninitialized memory + call CheckLegacyAndVim9Failure(["eval ''->printf()"], "E119:") endfunc func Test_printf_float() |