Read as many signals on the signal pipe as we can before returning.
This commit is contained in:
@@ -350,6 +350,7 @@ handle_signals(int fd, pid_t child, int log_io, struct command_status *cstat)
|
||||
int status;
|
||||
pid_t pid;
|
||||
|
||||
for (;;) {
|
||||
/* read signal pipe */
|
||||
nread = read(signal_pipe[0], &signo, sizeof(signo));
|
||||
if (nread <= 0) {
|
||||
@@ -400,6 +401,7 @@ handle_signals(int fd, pid_t child, int log_io, struct command_status *cstat)
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
return 1;
|
||||
}
|
||||
|
||||
|
Reference in New Issue
Block a user