uloop: retry waitpid on signal interrupt
Signed-off-by: Felix Fietkau <nbd@nbd.name>
This commit is contained in:
parent
6a75b3b643
commit
b06cd8c58e
1 changed files with 3 additions and 0 deletions
3
uloop.c
3
uloop.c
|
@ -311,6 +311,9 @@ static void uloop_handle_processes(void)
|
||||||
|
|
||||||
while (1) {
|
while (1) {
|
||||||
pid = waitpid(-1, &ret, WNOHANG);
|
pid = waitpid(-1, &ret, WNOHANG);
|
||||||
|
if (pid < 0 && errno == EINTR)
|
||||||
|
continue;
|
||||||
|
|
||||||
if (pid <= 0)
|
if (pid <= 0)
|
||||||
return;
|
return;
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue