sched/group/group_killchildren.c: Force-cancel children if parent is force-cancelled
There is no point in waiting for children to exit if the parent is force-cancelled Signed-off-by: Jukka Laitinen <jukkax@ssrc.tii.ae>
This commit is contained in:
parent
401b3e682c
commit
7c6b6171f5
@ -181,6 +181,9 @@ int group_kill_children(FAR struct tcb_s *tcb)
|
|||||||
|
|
||||||
#if defined(CONFIG_GROUP_KILL_CHILDREN_TIMEOUT_MS) && \
|
#if defined(CONFIG_GROUP_KILL_CHILDREN_TIMEOUT_MS) && \
|
||||||
CONFIG_GROUP_KILL_CHILDREN_TIMEOUT_MS != 0
|
CONFIG_GROUP_KILL_CHILDREN_TIMEOUT_MS != 0
|
||||||
|
|
||||||
|
if ((tcb->flags & TCB_FLAG_FORCED_CANCEL) == 0)
|
||||||
|
{
|
||||||
/* Send SIGTERM for each first */
|
/* Send SIGTERM for each first */
|
||||||
|
|
||||||
group_foreachchild(tcb->group, group_kill_children_handler,
|
group_foreachchild(tcb->group, group_kill_children_handler,
|
||||||
@ -206,6 +209,7 @@ int group_kill_children(FAR struct tcb_s *tcb)
|
|||||||
}
|
}
|
||||||
# endif
|
# endif
|
||||||
}
|
}
|
||||||
|
}
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
/* Force cancel/delete again */
|
/* Force cancel/delete again */
|
||||||
|
Loading…
Reference in New Issue
Block a user