simplify osx_write_pre_select()
[paraslash.git] / signal.c
index 6de9adf..f9b95f9 100644 (file)
--- a/signal.c
+++ b/signal.c
  */
 /** \file signal.c signal handling functions */
 
+
+
 #include "para.h"
 #include "fd.h"
+
+#include <signal.h>
+
 #include "error.h"
 static int signal_pipe[2];
 
@@ -84,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,