summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorjorton <jorton@13f79535-47bb-0310-9956-ffa450edef68>2006-06-14 14:11:17 +0000
committerjorton <jorton@13f79535-47bb-0310-9956-ffa450edef68>2006-06-14 14:11:17 +0000
commit8545dbf531fb8cca9b36559586eb8688127b06af (patch)
tree0bc289baac2ded978cb72d1272cc3fdf44bfb273
parentd9e7aa1b58f9eb906835272c0296cdcebe533c66 (diff)
downloadlibapr-8545dbf531fb8cca9b36559586eb8688127b06af.tar.gz
Merge r391580 from trunk:
* threadproc/unix/signals.c (apr_signal, avoid_zombies): Use the Darwin zombie-avoidance hack on NetBSD too. PR: 36750 Submitted by: Todd Vierling <tv pobox.com> git-svn-id: http://svn.apache.org/repos/asf/apr/apr/branches/1.2.x@414265 13f79535-47bb-0310-9956-ffa450edef68
-rw-r--r--threadproc/unix/signals.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/threadproc/unix/signals.c b/threadproc/unix/signals.c
index e2f0fe0f1..920d8aab4 100644
--- a/threadproc/unix/signals.c
+++ b/threadproc/unix/signals.c
@@ -55,7 +55,7 @@ APR_DECLARE(apr_status_t) apr_proc_kill(apr_proc_t *proc, int signum)
#if APR_HAVE_SIGACTION
-#ifdef DARWIN
+#if defined(__NetBSD__) || defined(DARWIN)
static void avoid_zombies(int signo)
{
int exit_status;
@@ -91,7 +91,7 @@ APR_DECLARE(apr_sigfunc_t *) apr_signal(int signo, apr_sigfunc_t * func)
act.sa_flags |= SA_NOCLDWAIT;
}
#endif
-#ifdef DARWIN
+#if defined(__NetBSD__) || defined(DARWIN)
/* ignoring SIGCHLD or leaving the default disposition doesn't avoid zombies,
* and there is no SA_NOCLDWAIT flag, so catch the signal and reap status in
* the handler to avoid zombies