]> git.ipfire.org Git - thirdparty/vim.git/commitdiff
patch 8.2.4937: no test for what 8.2.4931 fixes v8.2.4937
authorBram Moolenaar <Bram@vim.org>
Tue, 10 May 2022 20:11:12 +0000 (21:11 +0100)
committerBram Moolenaar <Bram@vim.org>
Tue, 10 May 2022 20:11:12 +0000 (21:11 +0100)
Problem:    No test for what 8.2.4931 fixes.
Solution:   Add a test that triggers a valgrind error.

src/testdir/test_perl.vim
src/version.c

index c35f49c8f33a25e774e0ad65ec383e44ae5729e0..cf4ca757303d7fe676dc7edb1439b0c3c22a9568 100644 (file)
@@ -308,6 +308,16 @@ func Test_000_SvREFCNT()
   %bw!
 endfunc
 
+" This caused a memory error before issue #10386 was fixed
+func Test_stack_usage_fix()
+   let script =<< CODE
+     " This will grow Perl's stack in first invocation
+     eval [0, 0]->map({ -> perleval("push@_,0..4096;0") })
+     q!
+CODE
+   call RunVim([], script, '')
+endfunc
+
 func Test_set_cursor()
   " Check that setting the cursor position works.
   new
index 7c49116a5424169716c492ffb9c37f1a16f203de..8cc9cebac386382d677d64d053bb4a9d665929bf 100644 (file)
@@ -746,6 +746,8 @@ static char *(features[]) =
 
 static int included_patches[] =
 {   /* Add new patch number below this line */
+/**/
+    4937,
 /**/
     4936,
 /**/