|
@@ -632,6 +632,8 @@ static void exit_notify(struct task_struct *tsk, int group_dead)
|
|
}
|
|
}
|
|
|
|
|
|
tsk->exit_state = autoreap ? EXIT_DEAD : EXIT_ZOMBIE;
|
|
tsk->exit_state = autoreap ? EXIT_DEAD : EXIT_ZOMBIE;
|
|
|
|
+ if (tsk->exit_state == EXIT_DEAD)
|
|
|
|
+ list_add(&tsk->ptrace_entry, &dead);
|
|
|
|
|
|
/* mt-exec, de_thread() is waiting for group leader */
|
|
/* mt-exec, de_thread() is waiting for group leader */
|
|
if (unlikely(tsk->signal->notify_count < 0))
|
|
if (unlikely(tsk->signal->notify_count < 0))
|
|
@@ -642,10 +644,6 @@ static void exit_notify(struct task_struct *tsk, int group_dead)
|
|
list_del_init(&p->ptrace_entry);
|
|
list_del_init(&p->ptrace_entry);
|
|
release_task(p);
|
|
release_task(p);
|
|
}
|
|
}
|
|
-
|
|
|
|
- /* If the process is dead, release it - nobody will wait for it */
|
|
|
|
- if (autoreap)
|
|
|
|
- release_task(tsk);
|
|
|
|
}
|
|
}
|
|
|
|
|
|
#ifdef CONFIG_DEBUG_STACK_USAGE
|
|
#ifdef CONFIG_DEBUG_STACK_USAGE
|