summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--fcgiwrap.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/fcgiwrap.c b/fcgiwrap.c
index e86ff9d..d4f7901 100644
--- a/fcgiwrap.c
+++ b/fcgiwrap.c
@@ -623,7 +623,7 @@ static void sigchld_handler(int dummy)
{
int status;
- while ((dummy = waitpid(-1, &status, WNOHANG)) != -1) {
+ while ((dummy = waitpid(-1, &status, WNOHANG)) > 0) {
/* sanity check */
if (nrunning > 0)
nrunning--;