Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Appearance settings

Commit f82c951

Browse filesBrowse files
friedambv
authored andcommitted
bpo-30395 _PyGILState_Reinit deadlock fix (#1734)
head_lock could be held by another thread when fork happened. We should reset it to avoid deadlock.
1 parent 1b9530c commit f82c951
Copy full SHA for f82c951

File tree

2 files changed

+5
-0
lines changed
Filter options

2 files changed

+5
-0
lines changed

‎Misc/ACKS

Copy file name to clipboardExpand all lines: Misc/ACKS
+1Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -556,6 +556,7 @@ Eric Groo
556556
Daniel Andrade Groppe
557557
Dag Gruneau
558558
Filip Gruszczyński
559+
Andrii Grynenko
559560
Grzegorz Grzywacz
560561
Thomas Guettler
561562
Yuyang Guo

‎Python/pystate.c

Copy file name to clipboardExpand all lines: Python/pystate.c
+4Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -744,6 +744,10 @@ _PyGILState_Fini(void)
744744
void
745745
_PyGILState_Reinit(void)
746746
{
747+
#ifdef WITH_THREAD
748+
head_mutex = NULL;
749+
HEAD_INIT();
750+
#endif
747751
PyThreadState *tstate = PyGILState_GetThisThreadState();
748752
PyThread_delete_key(autoTLSkey);
749753
if ((autoTLSkey = PyThread_create_key()) == -1)

0 commit comments

Comments
0 (0)
Morty Proxy This is a proxified and sanitized view of the page, visit original site.