From d45ce8b1dcbf25f8b0be713dcfabac2af192861d Mon Sep 17 00:00:00 2001 From: Ingo Weinhold Date: Wed, 3 Oct 2007 22:20:30 +0000 Subject: [PATCH] Move the job control entries of a dying team's children to the kernel team as well. Otherwise the children would later try to remove them from a list they weren't in. git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@22429 a95241bf-73f2-0310-859d-f6bbb57e9c96 --- src/system/kernel/team.cpp | 11 ++++++++++- 1 file changed, 10 insertions(+), 1 deletion(-) diff --git a/src/system/kernel/team.cpp b/src/system/kernel/team.cpp index edabef229c..7895313eab 100644 --- a/src/system/kernel/team.cpp +++ b/src/system/kernel/team.cpp @@ -402,6 +402,15 @@ reparent_children(struct team *team) remove_team_from_parent(team, child); insert_team_into_parent(sKernelTeam, child); } + + // move job control entries too + sKernelTeam->stopped_children->entries.MoveFrom( + &team->stopped_children->entries); + sKernelTeam->continued_children->entries.MoveFrom( + &team->continued_children->entries); + + // Note, we don't move the dead children entries. Those will be deleted + // when the team structure is deleted. } @@ -2050,7 +2059,7 @@ team_get_address_space(team_id id, vm_address_space **_addressSpace) /*! Sets the team's job control state. - Interrupts must be disabled and the team lock being held. + Interrupts must be disabled and the team lock be held. \a threadsLocked indicates whether the thread lock is being held, too. */ void