patch 9.2.0097: Memory leak in qf_push_dir()

Problem:  Memory leak in qf_push_dir() (after v9.2.0091)
Problem:  free dirname, if it is not a directory.

closes: #19552

Signed-off-by: Christian Brabandt <cb@256bit.org>
This commit is contained in:
Christian Brabandt
2026-03-03 18:25:24 +00:00
parent 327e0e34c9
commit e352bb632a
2 changed files with 3 additions and 1 deletions
+1 -1
View File
@@ -2841,7 +2841,7 @@ qf_push_dir(char_u *dirbuf, struct dir_stack_T **stackptr, int is_file_stack)
(*stackptr)->dirname = dirname;
break;
}
vim_free(dirname);
ds_new = ds_new->next;
}
+2
View File
@@ -734,6 +734,8 @@ static char *(features[]) =
static int included_patches[] =
{ /* Add new patch number below this line */
/**/
97,
/**/
96,
/**/