]> git.tue.mpg.de Git - paraslash.git/commitdiff
fix return value of para_reap_child()
authorAndre <maan@p133.(none)>
Tue, 20 Jun 2006 21:12:55 +0000 (23:12 +0200)
committerAndre <maan@p133.(none)>
Tue, 20 Jun 2006 21:12:55 +0000 (23:12 +0200)
In case of errors, this function returned 0 instead of -E_WAITPID.
Not a serious bug though.

signal.c

index 2d40d49bdc30cad6a926c3da7aa1bec71d5417df..f9b95f9006dee9c9cd558bb39bc0cc6c90ca1bb1 100644 (file)
--- a/signal.c
+++ b/signal.c
@@ -89,7 +89,7 @@ pid_t para_reap_child(void)
        if (pid <= 0) {
                if (pid < 0)
                        pid = -E_WAITPID;
-               return 0;
+               return pid;
        }
        if (WIFEXITED(status))
                PARA_DEBUG_LOG("child %i exited. Exit status: %i\n", pid,