summaryrefslogtreecommitdiff
path: root/kernel
diff options
context:
space:
mode:
Diffstat (limited to 'kernel')
-rw-r--r--kernel/pid.c1
1 files changed, 1 insertions, 0 deletions
diff --git a/kernel/pid.c b/kernel/pid.c
index f5afb3137e74..00413e3967b9 100644
--- a/kernel/pid.c
+++ b/kernel/pid.c
@@ -252,6 +252,7 @@ void switch_exec_pids(task_t *leader, task_t *thread)
attach_pid(thread, PIDTYPE_TGID, thread->tgid);
attach_pid(thread, PIDTYPE_PGID, thread->pgrp);
attach_pid(thread, PIDTYPE_SID, thread->session);
+ list_add_tail(&thread->tasks, &init_task.tasks);
attach_pid(leader, PIDTYPE_PID, leader->pid);
attach_pid(leader, PIDTYPE_TGID, leader->tgid);