Message344511
> commit 396e0a8d9dc65453cb9d53500d0a620602656cfe (refs/bisect/bad)
Extract of this change:
static inline void
-exit_thread_if_finalizing(_PyRuntimeState *runtime, PyThreadState *tstate)
+exit_thread_if_finalizing(PyThreadState *tstate)
{
+ _PyRuntimeState *runtime = tstate->interp->runtime;
/* _Py_Finalizing is protected by the GIL */
if (runtime->finalizing != NULL && !_Py_CURRENTLY_FINALIZING(runtime, tstate)) {
drop_gil(&runtime->ceval, tstate);
@@ -236,7 +237,7 @@ PyEval_AcquireLock(void)
Py_FatalError("PyEval_AcquireLock: current thread state is NULL");
}
take_gil(ceval, tstate);
- exit_thread_if_finalizing(runtime, tstate);
+ exit_thread_if_finalizing(tstate);
}
This change is fine for regular Python threads. But for daemon threads, tstate is likely already corrupted, so it's no longer possible to get interp from interp, and so also not possible to get 'runtime'. |
|
| Date |
User |
Action |
Args |
| 2019-06-04 01:01:52 | vstinner | set | recipients:
+ vstinner, pitrou, lukasz.langa, koobs, pablogsal |
| 2019-06-04 01:01:52 | vstinner | set | messageid: <[email protected]> |
| 2019-06-04 01:01:52 | vstinner | link | issue37135 messages |
| 2019-06-04 01:01:52 | vstinner | create | |
|