0
0
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:
Bram Moolenaar
2013-12-07 14:28:43 +01:00
parent ba2d44f338
commit c2401d62e0
2 changed files with 7 additions and 2 deletions

View File

@@ -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;
}

View File

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