Issue #8407: pthread_sigmask() checks immediatly if signal handlers have been

called. The test checks that SIG_UNBLOCK calls immediatly the signal handler of
the pending SIGUSR1. Improve also the tests using an exception (division by
zero) instead of a flag (a function attribute).
This commit is contained in:
Victor Stinner 2011-05-03 14:57:12 +02:00
parent 2d4a91e0d0
commit d0e516db50
2 changed files with 20 additions and 14 deletions

View file

@ -573,6 +573,10 @@ signal_pthread_sigmask(PyObject *self, PyObject *args)
return NULL;
}
/* if signals was unblocked, signal handlers have been called */
if (PyErr_CheckSignals())
return NULL;
result = PyList_New(0);
if (result == NULL)
return NULL;