This commit is contained in:
algonell 2024-09-09 15:58:26 +03:00 committed by GitHub
parent df4f0cbfad
commit 9017b95ff2
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
43 changed files with 59 additions and 59 deletions

View file

@ -314,8 +314,8 @@ thread_run(void *boot_raw)
// gh-108987: If _thread.start_new_thread() is called before or while
// Python is being finalized, thread_run() can called *after*.
// _PyRuntimeState_SetFinalizing() is called. At this point, all Python
// threads must exit, except of the thread calling Py_Finalize() whch holds
// the GIL and must not exit.
// threads must exit, except of the thread calling Py_Finalize() which
// holds the GIL and must not exit.
//
// At this stage, tstate can be a dangling pointer (point to freed memory),
// it's ok to call _PyThreadState_MustExit() with a dangling pointer.