Skip to content

Commit

Permalink
core: exit with failure code if a child dies
Browse files Browse the repository at this point in the history
  • Loading branch information
camilleoudot committed Nov 19, 2015
1 parent 16bc7b7 commit dd7854e
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion main.c
Expand Up @@ -755,7 +755,11 @@ void handle_sigs(void)
/* exit */
shutdown_children(SIGTERM, 1);
LM_DBG("terminating due to SIGCHLD\n");
exit(0);
if (WIFSIGNALED(chld_status)) {
exit(1);
} else {
exit(0);
}
break;

case SIGHUP: /* ignoring it*/
Expand Down

0 comments on commit dd7854e

Please sign in to comment.