summaryrefslogtreecommitdiffstats
path: root/Python
diff options
context:
space:
mode:
Diffstat (limited to 'Python')
-rw-r--r--Python/pylifecycle.c6
1 files changed, 2 insertions, 4 deletions
diff --git a/Python/pylifecycle.c b/Python/pylifecycle.c
index 2d219a4..ab5a676 100644
--- a/Python/pylifecycle.c
+++ b/Python/pylifecycle.c
@@ -1286,10 +1286,8 @@ finalize_interp_clear(PyThreadState *tstate)
/* Clear interpreter state and all thread states */
PyInterpreterState_Clear(tstate->interp);
- /* Trigger a GC collection on subinterpreters*/
- if (!is_main_interp) {
- _PyGC_CollectNoFail();
- }
+ /* Last explicit GC collection */
+ _PyGC_CollectNoFail();
/* Clear all loghooks */
/* Both _PySys_Audit function and users still need PyObject, such as tuple.