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

patch 8.1.2291: memory leak when executing command in a terminal

Problem:    Memory leak when executing command in a terminal.
Solution:   Free "argv". (Dominique Pelle, closes #5208)
This commit is contained in:
Bram Moolenaar 2019-11-10 22:36:44 +01:00
parent 5ef1c6a483
commit adf4aa200b
2 changed files with 3 additions and 0 deletions

View File

@ -844,6 +844,7 @@ ex_terminal(exarg_T *eap)
// :term ++shell command
if (unix_build_argv(cmd, &argv, &tofree1, &tofree2) == OK)
term_start(NULL, argv, &opt, eap->forceit ? TERM_START_FORCEIT : 0);
vim_free(argv);
vim_free(tofree1);
vim_free(tofree2);
goto theend;

View File

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