diff options
author | Berker Peksag <berker.peksag@gmail.com> | 2016-07-23 07:13:14 +0300 |
---|---|---|
committer | Berker Peksag <berker.peksag@gmail.com> | 2016-07-23 07:13:14 +0300 |
commit | 1fd497ed91a14eabaf37e9b3f17dde8c3169ef25 (patch) | |
tree | 28c09ff0aacd4cded3be1defcdbfd92d4f388a4f /Modules/_multiprocessing | |
parent | Issue #27130: Fix handling of buffers exceeding UINT_MAX in “zlib” module (diff) | |
download | cpython-1fd497ed91a14eabaf37e9b3f17dde8c3169ef25.tar.gz cpython-1fd497ed91a14eabaf37e9b3f17dde8c3169ef25.tar.bz2 cpython-1fd497ed91a14eabaf37e9b3f17dde8c3169ef25.zip |
Issue #27591: Set sigint_event to NULL if _PyOS_IsMainThread() returns false
Patch by Chris Angelico.
Diffstat (limited to 'Modules/_multiprocessing')
-rw-r--r-- | Modules/_multiprocessing/semaphore.c | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/Modules/_multiprocessing/semaphore.c b/Modules/_multiprocessing/semaphore.c index de85a90d472..cea962ab26c 100644 --- a/Modules/_multiprocessing/semaphore.c +++ b/Modules/_multiprocessing/semaphore.c @@ -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 |