mirror of
https://github.com/owntone/owntone-server.git
synced 2025-02-04 10:26:02 -05:00
[main] Use waitpid instead of obsolete wait3
This commit is contained in:
parent
ac290b8b65
commit
9355015b3c
@ -346,9 +346,9 @@ signal_signalfd_cb(int fd, short event, void *arg)
|
|||||||
switch (info.ssi_signo)
|
switch (info.ssi_signo)
|
||||||
{
|
{
|
||||||
case SIGCHLD:
|
case SIGCHLD:
|
||||||
DPRINTF(E_LOG, L_MAIN, "Got SIGCHLD, reaping children\n");
|
DPRINTF(E_LOG, L_MAIN, "Got SIGCHLD\n");
|
||||||
|
|
||||||
while (wait3(&status, WNOHANG, NULL) > 0)
|
while (waitpid(-1, &status, WNOHANG) > 0)
|
||||||
/* Nothing. */ ;
|
/* Nothing. */ ;
|
||||||
break;
|
break;
|
||||||
|
|
||||||
@ -391,9 +391,9 @@ signal_kqueue_cb(int fd, short event, void *arg)
|
|||||||
switch (ke.ident)
|
switch (ke.ident)
|
||||||
{
|
{
|
||||||
case SIGCHLD:
|
case SIGCHLD:
|
||||||
DPRINTF(E_LOG, L_MAIN, "Got SIGCHLD, reaping children\n");
|
DPRINTF(E_LOG, L_MAIN, "Got SIGCHLD\n");
|
||||||
|
|
||||||
while (wait3(&status, WNOHANG, NULL) > 0)
|
while (waitpid(-1, &status, WNOHANG) > 0)
|
||||||
/* Nothing. */ ;
|
/* Nothing. */ ;
|
||||||
break;
|
break;
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user