chiark / gitweb /
client/tripectl.c: Unblock SIGCHLD in child.
authorMark Wooding <mdw@distorted.org.uk>
Tue, 13 Mar 2012 02:27:13 +0000 (02:27 +0000)
committerMark Wooding <mdw@distorted.org.uk>
Tue, 13 Mar 2012 02:27:13 +0000 (02:27 +0000)
Otherwise it accumulates zombies like they're going out of fashion.

client/tripectl.c

index ea86ec5..f818de8 100644 (file)
@@ -520,6 +520,7 @@ int main(int argc, char *argv[])
       die(EXIT_FAILURE, "fork failed: %s", strerror(errno));
     if (!kid) {
       close(pfd[0]); close(efd[0]);
+      sigprocmask(SIG_SETMASK, &oldmask, 0);
       md[0].cur = pfd[1]; md[0].want = STDIN_FILENO;
       md[1].cur = pfd[1]; md[1].want = STDOUT_FILENO;
       md[2].cur = efd[1]; md[2].want = STDERR_FILENO;