diff options
author | Joe Orton <jorton@apache.org> | 2006-04-05 10:54:26 +0000 |
---|---|---|
committer | Joe Orton <jorton@apache.org> | 2006-04-05 10:54:26 +0000 |
commit | d7abd11faba3d77cfa92f759225401bf48eee044 (patch) | |
tree | 4d1f51d3f07850e94b94e055731ecbeac86d4737 | |
parent | c6b3812dc476e89c10ab956286699714b180b38d (diff) | |
download | apr-d7abd11faba3d77cfa92f759225401bf48eee044.tar.gz apr-d7abd11faba3d77cfa92f759225401bf48eee044.zip |
* 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: https://svn.apache.org/repos/asf/apr/apr/trunk@391580 13f79535-47bb-0310-9956-ffa450edef68
-rw-r--r-- | CHANGES | 3 | ||||
-rw-r--r-- | threadproc/unix/signals.c | 4 |
2 files changed, 5 insertions, 2 deletions
@@ -1,5 +1,8 @@ Changes for APR 1.3.0 + *) NetBSD: Avoid leaving zombie process when using apr_signal() + to ignore SIGCHLD. PR 36750. [Todd Vierling <tv pobox.com>] + *) Correct bug in kqueue backend for apr_pollset where we would erroneously indicate that a socket was readable or writeable. [Garrett Rooney] 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 |