]> git.ipfire.org Git - thirdparty/rsync.git/commitdiff
continue calling waitpid() while still reapingchildren (patch from
authorAndrew Tridgell <tridge@samba.org>
Sun, 27 Jun 1999 04:12:12 +0000 (04:12 +0000)
committerAndrew Tridgell <tridge@samba.org>
Sun, 27 Jun 1999 04:12:12 +0000 (04:12 +0000)
Matti Aarnio)

socket.c

index eb25d8cc93ae97a4fe21f9930c6d070d1a07a47b..4c81d59712361fcc12ab0c5c9d17cf84bef97fed 100644 (file)
--- a/socket.c
+++ b/socket.c
@@ -255,7 +255,7 @@ void start_accept_loop(int port, int (*fn)(int ))
                   but I have had reports that on Digital Unix zombies
                   are produced, so this ensures that they are reaped */
 #ifdef WNOHANG
-               waitpid(-1, NULL, WNOHANG);
+                while (waitpid(-1, NULL, WNOHANG) > 0);
 #endif
 
                if (fork()==0) {