mirror of
https://github.com/vim/vim.git
synced 2025-09-25 03:54:15 -04:00
patch 8.0.0356: leaking memory when setting 'ttytype'
Problem: Leaking memory when setting 'ttytype'. Solution: Get free_oldval from the right option entry.
This commit is contained in:
@@ -5936,6 +5936,7 @@ did_set_string_option(
|
|||||||
/* Both 'term' and 'ttytype' point to T_NAME, only set the
|
/* Both 'term' and 'ttytype' point to T_NAME, only set the
|
||||||
* P_ALLOCED flag on 'term'. */
|
* P_ALLOCED flag on 'term'. */
|
||||||
opt_idx = findoption((char_u *)"term");
|
opt_idx = findoption((char_u *)"term");
|
||||||
|
free_oldval = (options[opt_idx].flags & P_ALLOCED);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@@ -764,6 +764,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 */
|
||||||
|
/**/
|
||||||
|
356,
|
||||||
/**/
|
/**/
|
||||||
355,
|
355,
|
||||||
/**/
|
/**/
|
||||||
|
Reference in New Issue
Block a user