Commit 13cc6794 authored by Serhiy Storchaka's avatar Serhiy Storchaka

Issue #24469: Fixed memory leak caused by int subclasses without overridden

tp_free (e.g. C-inherited Cython classes).
parent 0092bc72
......@@ -10,6 +10,9 @@ What's New in Python 2.7.13?
Core and Builtins
-----------------
- Issue #24469: Fixed memory leak caused by int subclasses without overridden
tp_free (e.g. C-inherited Cython classes).
- Issue #19398: Extra slash no longer added to sys.path components in case of
empty compile-time PYTHONPATH components.
......
......@@ -139,13 +139,6 @@ int_dealloc(PyIntObject *v)
Py_TYPE(v)->tp_free((PyObject *)v);
}
static void
int_free(PyIntObject *v)
{
Py_TYPE(v) = (struct _typeobject *)free_list;
free_list = v;
}
long
PyInt_AsLong(register PyObject *op)
{
......@@ -1451,7 +1444,6 @@ PyTypeObject PyInt_Type = {
0, /* tp_init */
0, /* tp_alloc */
int_new, /* tp_new */
(freefunc)int_free, /* tp_free */
};
int
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment