waitid(P_ALL, 0, &info, WEXITED), where it infohas a type siginfo_t, collects the same child processes as wait(&status). They differ
- argument
siginfo_t * waitid()and its interpretation in comparison with argument int * wait()and its interpretation, and - .
, waitid() , : waitid(P_PID, pid, &info, WEXITED).
, wait() pid , , waitid() 0 .
, siginfo_t si_status, wait(), . siginfo_t.si_status - , , wait(), . WEXITSTATUS(), , (WIFEXITED()) (WIFSIGNALED()).