mirror of
https://github.com/vim/vim.git
synced 2025-09-25 03:54:15 -04:00
updated for version 7.4.111
Problem: Memory leak in Python OptionsAssItem. (Ken Takata) Solution: Call Py_XDECREF() where needed. (ZyX)
This commit is contained in:
@@ -3005,11 +3005,14 @@ OptionsAssItem(OptionsObject *self, PyObject *keyObject, PyObject *valObject)
|
||||
else
|
||||
{
|
||||
char_u *val;
|
||||
PyObject *todecref;
|
||||
PyObject *todecref2;
|
||||
|
||||
if ((val = StringToChars(valObject, &todecref)))
|
||||
if ((val = StringToChars(valObject, &todecref2)))
|
||||
{
|
||||
ret = set_option_value_for(key, 0, val, opt_flags,
|
||||
self->opt_type, self->from);
|
||||
Py_XDECREF(todecref2);
|
||||
}
|
||||
else
|
||||
ret = -1;
|
||||
}
|
||||
|
@@ -738,6 +738,8 @@ static char *(features[]) =
|
||||
|
||||
static int included_patches[] =
|
||||
{ /* Add new patch number below this line */
|
||||
/**/
|
||||
111,
|
||||
/**/
|
||||
110,
|
||||
/**/
|
||||
|
Reference in New Issue
Block a user