0
0
mirror of https://github.com/vim/vim.git synced 2025-07-26 11:04:33 -04:00

patch 8.2.1709: Vim9: memory leak when using multiple closures

Problem:    Vim9: memory leak when using multiple closures.
Solution:   Free the partial.
This commit is contained in:
Bram Moolenaar 2020-09-18 23:11:10 +02:00
parent b185a40745
commit dec07510bb
2 changed files with 3 additions and 0 deletions

View File

@ -750,6 +750,8 @@ static char *(features[]) =
static int included_patches[] = static int included_patches[] =
{ /* Add new patch number below this line */ { /* Add new patch number below this line */
/**/
1709,
/**/ /**/
1708, 1708,
/**/ /**/

View File

@ -1830,6 +1830,7 @@ call_def_function(
// TODO: use a garray_T on ectx. // TODO: use a garray_T on ectx.
SOURCING_LNUM = iptr->isn_lnum; SOURCING_LNUM = iptr->isn_lnum;
emsg("Multiple closures not supported yet"); emsg("Multiple closures not supported yet");
vim_free(pt);
goto failed; goto failed;
} }
tv->v_type = VAR_PARTIAL; tv->v_type = VAR_PARTIAL;