summaryrefslogtreecommitdiff
path: root/Objects/codeobject.c
diff options
context:
space:
mode:
Diffstat (limited to 'Objects/codeobject.c')
-rw-r--r--Objects/codeobject.c1
1 files changed, 1 insertions, 0 deletions
diff --git a/Objects/codeobject.c b/Objects/codeobject.c
index 7a0080c08c..8920b1db2c 100644
--- a/Objects/codeobject.c
+++ b/Objects/codeobject.c
@@ -2238,6 +2238,7 @@ _PyStaticCode_Dealloc(PyCodeObject *co)
Py_CLEAR(co->_co_cached->_co_freevars);
Py_CLEAR(co->_co_cached->_co_varnames);
PyMem_Free(co->_co_cached);
+ co->_co_cached = NULL;
}
co->co_extra = NULL;
if (co->co_weakreflist != NULL) {