This issue tracker has been migrated to GitHub, and is currently read-only.
For more information, see the GitHub FAQs in the Python's Developer Guide.

Author pitrou
Recipients hroncok, ned.deily, pitrou
Date 2018-04-22.12:11:53
SpamBayes Score -1.0
Marked as misclassified Yes
Message-id <1524399113.33.0.682650639539.issue33329@psf.upfronthosting.co.za>
In-reply-to
Content
Miro, can you give the following patch a try?

diff --git a/Modules/signalmodule.c b/Modules/signalmodule.c
index 7916160..ca76a20 100644
--- a/Modules/signalmodule.c
+++ b/Modules/signalmodule.c
@@ -819,7 +819,6 @@ iterable_to_sigset(PyObject *iterable, sigset_t *mask)
     int result = -1;
     PyObject *iterator, *item;
     long signum;
-    int err;
 
     sigemptyset(mask);
 
@@ -841,11 +840,10 @@ iterable_to_sigset(PyObject *iterable, sigset_t *mask)
         Py_DECREF(item);
         if (signum == -1 && PyErr_Occurred())
             goto error;
-        if (0 < signum && signum < NSIG)
-            err = sigaddset(mask, (int)signum);
-        else
-            err = 1;
-        if (err) {
+        if (0 < signum && signum < NSIG) {
+            (void) sigaddset(mask, (int)signum);
+        }
+        else {
             PyErr_Format(PyExc_ValueError,
                          "signal number %ld out of range", signum);
             goto error;
History
Date User Action Args
2018-04-22 12:11:53pitrousetrecipients: + pitrou, ned.deily, hroncok
2018-04-22 12:11:53pitrousetmessageid: <1524399113.33.0.682650639539.issue33329@psf.upfronthosting.co.za>
2018-04-22 12:11:53pitroulinkissue33329 messages
2018-04-22 12:11:53pitroucreate