Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Commit e6bfdb9

Browse files
committed
merge 3.4
2 parents 61f1acc + 17548dd commit e6bfdb9

1 file changed

Lines changed: 7 additions & 0 deletions

File tree

Python/ceval.c

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1267,6 +1267,13 @@ PyEval_EvalFrameEx(PyFrameObject *f, int throwflag)
12671267
/* Other threads may run now */
12681268

12691269
take_gil(tstate);
1270+
1271+
/* Check if we should make a quick exit. */
1272+
if (_Py_Finalizing && _Py_Finalizing != tstate) {
1273+
drop_gil(tstate);
1274+
PyThread_exit_thread();
1275+
}
1276+
12701277
if (PyThreadState_Swap(tstate) != NULL)
12711278
Py_FatalError("ceval: orphan tstate");
12721279
}

0 commit comments

Comments
 (0)