cvs: php4 / main.c
| From: | Thies C. Arntzen | Date: | Fri, 19 May 2000 10:40:34 +0000 |
| Subject: | cvs: php4 / main.c | ||
| Groups: | php.version4 | ||
| Request: | Send a blank email to php-version4+get-15233@lists.php.net to get a copy of this message | ||
thies Fri May 19 12:40:34 2000 EDT
Modified files:
/php4 main.c
Log:
make sigchild handler more robust.
Index: php4/main.c
diff -u php4/main.c:1.246 php4/main.c:1.247
--- php4/main.c:1.246 Thu May 18 21:45:34 2000
+++ php4/main.c Fri May 19 12:40:34 2000
@@ -19,7 +19,7 @@
*/
-/* $Id: main.c,v 1.246 2000/05/18 19:45:34 thies Exp $ */
+/* $Id: main.c,v 1.247 2000/05/19 10:40:34 thies Exp $ */
#include <stdio.h>
@@ -640,8 +640,8 @@
#if PHP_SIGCHILD
static int sigchld_handler(int apar)
{
- int status;
- wait(&status);
+ while (waitpid(-1, NULL, WNOHANG) > 0)
+ ;
signal(SIGCHLD,sigchld_handler);
}
#endif