mirror of
https://github.com/vim/vim.git
synced 2025-10-21 08:24:06 -04:00
patch 9.1.1749: leaking memory in cs_find_common()
Problem: leaking memory in cs_find_common() (after v9.1.1746) Solution: Also free nummatches before returning closes: #18258 Signed-off-by: Christian Brabandt <cb@256bit.org>
This commit is contained in:
@@ -1233,7 +1233,10 @@ cs_find_common(
|
|||||||
win_T *wp = NULL;
|
win_T *wp = NULL;
|
||||||
|
|
||||||
if (tmp == NULL)
|
if (tmp == NULL)
|
||||||
|
{
|
||||||
|
vim_free(nummatches);
|
||||||
return FALSE;
|
return FALSE;
|
||||||
|
}
|
||||||
|
|
||||||
f = mch_fopen((char *)tmp, "w");
|
f = mch_fopen((char *)tmp, "w");
|
||||||
if (f == NULL)
|
if (f == NULL)
|
||||||
|
@@ -724,6 +724,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 */
|
||||||
|
/**/
|
||||||
|
1749,
|
||||||
/**/
|
/**/
|
||||||
1748,
|
1748,
|
||||||
/**/
|
/**/
|
||||||
|
Reference in New Issue
Block a user