diff options
Diffstat (limited to 'Python/pylifecycle.c')
-rw-r--r-- | Python/pylifecycle.c | 24 |
1 files changed, 0 insertions, 24 deletions
diff --git a/Python/pylifecycle.c b/Python/pylifecycle.c index 088e7aa931..a5cfc07c48 100644 --- a/Python/pylifecycle.c +++ b/Python/pylifecycle.c @@ -1460,32 +1460,8 @@ Py_EndInterpreter(PyThreadState *tstate) if (tstate->frame != NULL) Py_FatalError("Py_EndInterpreter: thread still has a frame"); - // Mark as finalizing. - if (interp->ceval.pending.lock != NULL) { - PyThread_acquire_lock(interp->ceval.pending.lock, 1); - } - interp->finalizing = 1; - if (interp->ceval.pending.lock != NULL) { - PyThread_release_lock(interp->ceval.pending.lock); - } - - // Wrap up existing threads. wait_for_thread_shutdown(); - // Make any pending calls. - if (_Py_atomic_load_relaxed( - &(interp->ceval.pending.calls_to_do))) - { - // XXX Ensure that the interpreter is running in the current thread? - if (_Py_MakePendingCalls(interp) < 0) { - PyObject *exc, *val, *tb; - PyErr_Fetch(&exc, &val, &tb); - PyErr_BadInternalCall(); - _PyErr_ChainExceptions(exc, val, tb); - PyErr_Print(); - } - } - call_py_exitfuncs(interp); if (tstate != interp->tstate_head || tstate->next != NULL) |