mirror of
https://github.com/python/cpython.git
synced 2025-08-04 08:59:19 +00:00
Issue #27591: Set sigint_event to NULL if _PyOS_IsMainThread() returns false
Patch by Chris Angelico.
This commit is contained in:
parent
84544c1020
commit
1fd497ed91
1 changed files with 3 additions and 0 deletions
|
@ -114,6 +114,9 @@ semlock_acquire(SemLockObject *self, PyObject *args, PyObject *kwds)
|
|||
assert(sigint_event != NULL);
|
||||
handles[nhandles++] = sigint_event;
|
||||
}
|
||||
else {
|
||||
sigint_event = NULL;
|
||||
}
|
||||
|
||||
/* do the wait */
|
||||
Py_BEGIN_ALLOW_THREADS
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue