Thanks to visit codestin.com Credit goes to github.com
We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 0c3f8a4 commit e4bc7f6Copy full SHA for e4bc7f6
2 files changed
Misc/NEWS
@@ -12,6 +12,9 @@ What's New in Python 3.1 alpha 0
12
Core and Builtins
13
-----------------
14
15
+- Issue #4838: When a module is deallocated, free the memory backing the
16
+ optional module state data.
17
+
18
- Issue #4910: Rename nb_long slot to nb_reserved, and change its
19
type to (void *).
20
Objects/moduleobject.c
@@ -315,6 +315,8 @@ module_dealloc(PyModuleObject *m)
315
_PyModule_Clear((PyObject *)m);
316
Py_DECREF(m->md_dict);
317
}
318
+ if (m->md_state != NULL)
319
+ PyMem_FREE(m->md_state);
320
Py_TYPE(m)->tp_free((PyObject *)m);
321
322
0 commit comments