ched/sched/sched_waitpid.c: In waitpid, remember to grab the exited child ptr. After being unblocked in waitpid, the child pointer might be NULL. Modify to use group_exitchild to get the pointer of recent exited child.
This commit is contained in:
parent
19f9e0038e
commit
8181a92a1d
|
@ -542,6 +542,7 @@ pid_t waitpid(pid_t pid, int *stat_loc, int options)
|
|||
#ifdef CONFIG_SCHED_CHILD_STATUS
|
||||
if (retains)
|
||||
{
|
||||
child = group_exitchild(rtcb->group);
|
||||
DEBUGASSERT(child != NULL);
|
||||
|
||||
/* Discard the child entry */
|
||||
|
|
Loading…
Reference in New Issue