summaryrefslogtreecommitdiffstats
path: root/Python/pystate.c
diff options
context:
space:
mode:
Diffstat (limited to 'Python/pystate.c')
-rw-r--r--Python/pystate.c3
1 files changed, 3 insertions, 0 deletions
diff --git a/Python/pystate.c b/Python/pystate.c
index 3a2966c..4d42135 100644
--- a/Python/pystate.c
+++ b/Python/pystate.c
@@ -482,6 +482,9 @@ _PyRuntimeState_Init(_PyRuntimeState *runtime)
void
_PyRuntimeState_Fini(_PyRuntimeState *runtime)
{
+ /* The reftotal is cleared by _Py_FinalizeRefTotal(). */
+ assert(runtime->object_state.reftotal == 0);
+
if (gilstate_tss_initialized(runtime)) {
gilstate_tss_fini(runtime);
}