Kaydet (Commit) 8cf04764 authored tarafından Guido van Rossum's avatar Guido van Rossum

Added internal routine PyString_Fini() which deletes all interned

strings.  For use in Py_Finalize() only.
üst 29e46a9a
......@@ -1073,3 +1073,21 @@ PyString_InternFromString(cp)
}
#endif
void
PyString_Fini()
{
int i;
#ifdef INTERN_STRINGS
Py_XDECREF(interned);
interned = NULL;
#endif
for (i = 0; i < UCHAR_MAX + 1; i++) {
Py_XDECREF(characters[i]);
characters[i] = NULL;
}
#ifndef DONT_SHARE_SHORT_STRINGS
Py_XDECREF(nullstring);
nullstring = NULL;
#endif
}
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