Patch 8.2.2087
Problem: Vim9: memory leak when statement is truncated.
Solution: Increment the number of local variables.
Files: src/vim9compile.c
*** ../vim-8.2.2086/src/vim9compile.c 2020-12-02 17:36:49.173409740 +0100
--- src/vim9compile.c 2020-12-04 12:40:16.266937523 +0100
***************
*** 5669,5675 ****
--- 5669,5679 ----
wp = op + oplen;
p = skipwhite(wp);
if (may_get_next_line_error(wp, &p, cctx) == FAIL)
+ {
+ if (new_local)
+ ++cctx->ctx_locals.ga_len;
goto theend;
+ }
r = compile_expr0_ext(&p, cctx, &is_const);
if (new_local)
++cctx->ctx_locals.ga_len;
*** ../vim-8.2.2086/src/version.c 2020-12-03 21:24:04.089645975 +0100
--- src/version.c 2020-12-04 12:43:09.610427783 +0100
***************
*** 752,753 ****
--- 752,755 ----
{ /* Add new patch number below this line */
+ /**/
+ 2087,
/**/
--
If "R" is Reverse, how come "D" is FORWARD?
/// Bram Moolenaar -- Br...@Moolenaar.net --
http://www.Moolenaar.net \\\
/// sponsor Vim, vote for features --
http://www.Vim.org/sponsor/ \\\
\\\ an exciting new programming language --
http://www.Zimbu.org ///
\\\ help me help AIDS victims --
http://ICCF-Holland.org ///