[Python-checkins] r68672 - in python/branches/release30-maint: Misc/NEWS Objects/moduleobject.c
antoine.pitrou
python-checkins at python.org
Sat Jan 17 22:40:04 CET 2009
Author: antoine.pitrou
Date: Sat Jan 17 22:40:04 2009
New Revision: 68672
Log:
Merged revisions 68669 via svnmerge from
svn+ssh://pythondev@svn.python.org/python/branches/py3k
........
r68669 | antoine.pitrou | 2009-01-17 22:06:43 +0100 (sam., 17 janv. 2009) | 3 lines
Issue #4838: When a module is deallocated, free the memory backing the optional module state data.
........
Modified:
python/branches/release30-maint/ (props changed)
python/branches/release30-maint/Misc/NEWS
python/branches/release30-maint/Objects/moduleobject.c
Modified: python/branches/release30-maint/Misc/NEWS
==============================================================================
--- python/branches/release30-maint/Misc/NEWS (original)
+++ python/branches/release30-maint/Misc/NEWS Sat Jan 17 22:40:04 2009
@@ -12,6 +12,9 @@
Core and Builtins
-----------------
+- Issue #4838: When a module is deallocated, free the memory backing the
+ optional module state data.
+
- Issue #4910: Rename nb_long slot to nb_reserved, and change its
type to (void *).
Modified: python/branches/release30-maint/Objects/moduleobject.c
==============================================================================
--- python/branches/release30-maint/Objects/moduleobject.c (original)
+++ python/branches/release30-maint/Objects/moduleobject.c Sat Jan 17 22:40:04 2009
@@ -315,6 +315,8 @@
_PyModule_Clear((PyObject *)m);
Py_DECREF(m->md_dict);
}
+ if (m->md_state != NULL)
+ PyMem_FREE(m->md_state);
Py_TYPE(m)->tp_free((PyObject *)m);
}
More information about the Python-checkins
mailing list