mirror of
https://github.com/python/cpython.git
synced 2025-07-19 01:05:26 +00:00
Merge.
This commit is contained in:
commit
3f32fc87ad
2 changed files with 26 additions and 1 deletions
|
@ -1403,12 +1403,14 @@ void
|
|||
PyOS_AfterFork(void)
|
||||
{
|
||||
#ifdef WITH_THREAD
|
||||
/* PyThread_ReInitTLS() must be called early, to make sure that the TLS API
|
||||
* can be called safely. */
|
||||
PyThread_ReInitTLS();
|
||||
_PyGILState_Reinit();
|
||||
PyEval_ReInitThreads();
|
||||
main_thread = PyThread_get_thread_ident();
|
||||
main_pid = getpid();
|
||||
_PyImport_ReInitLock();
|
||||
PyThread_ReInitTLS();
|
||||
#endif
|
||||
}
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue