summaryrefslogtreecommitdiff
path: root/threadproc/unix/signals.c
diff options
context:
space:
mode:
authorJeff Trawick <trawick@apache.org>2002-08-08 19:14:19 +0000
committerJeff Trawick <trawick@apache.org>2002-08-08 19:14:19 +0000
commit3c1a6293f40822d97df74537ab6ad274be2d3b24 (patch)
tree9629538e2b99e2e45e35bbbbca5db25af1f9277e /threadproc/unix/signals.c
parentaf9ad622a5467e7e164aaf1a500e5e9c83156cd7 (diff)
downloadapr-3c1a6293f40822d97df74537ab6ad274be2d3b24.tar.gz
In apr_signal_thread() remove synchronous signals from the mask
passed to sigwait(). It is never valid for them to be there. Some platforms silently ignore them, some return EINVAL, some don't process it as desired. One problem was found with an old Apache 2.0.30 build on AIX. sig_coredump() wasn't getting called when a plug-in generated SIGABRT. Removing SIGABRT from the signal mask passed to sigwait() by the main worker thread fixed the problem. After reviewing sigwait() documentation it was clear that none of the synchronous signals should be in the mask passed to sigwait(). git-svn-id: https://svn.apache.org/repos/asf/apr/apr/trunk@63802 13f79535-47bb-0310-9956-ffa450edef68
Diffstat (limited to 'threadproc/unix/signals.c')
-rw-r--r--threadproc/unix/signals.c3
1 files changed, 3 insertions, 0 deletions
diff --git a/threadproc/unix/signals.c b/threadproc/unix/signals.c
index b8cfc6798..fa4867b9b 100644
--- a/threadproc/unix/signals.c
+++ b/threadproc/unix/signals.c
@@ -374,6 +374,9 @@ APR_DECLARE(apr_status_t) apr_signal_thread(int(*signal_handler)(int signum))
sigdelset(&sig_mask, SIGWAITING);
#endif
+ /* no synchronous signals should be in the mask passed to sigwait() */
+ remove_sync_sigs(&sig_mask);
+
/* On AIX (4.3.3, at least), sigwait() won't wake up if the high-
* order bit of the second word of flags is turned on. sigdelset()
* returns an error when trying to turn this off, so we'll turn it