aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--kernel/exit.c4
-rw-r--r--kernel/ptrace.c8
2 files changed, 6 insertions, 6 deletions
diff --git a/kernel/exit.c b/kernel/exit.c
index df26c33037d2..5b5e8b67680e 100644
--- a/kernel/exit.c
+++ b/kernel/exit.c
@@ -238,10 +238,10 @@ static void reparent_to_init(void)
238 238
239 ptrace_unlink(current); 239 ptrace_unlink(current);
240 /* Reparent to init */ 240 /* Reparent to init */
241 REMOVE_LINKS(current); 241 remove_parent(current);
242 current->parent = child_reaper; 242 current->parent = child_reaper;
243 current->real_parent = child_reaper; 243 current->real_parent = child_reaper;
244 SET_LINKS(current); 244 add_parent(current);
245 245
246 /* Set the exit signal to SIGCHLD so we signal init on exit */ 246 /* Set the exit signal to SIGCHLD so we signal init on exit */
247 current->exit_signal = SIGCHLD; 247 current->exit_signal = SIGCHLD;
diff --git a/kernel/ptrace.c b/kernel/ptrace.c
index d95a72c9279d..86a7f6c60cb2 100644
--- a/kernel/ptrace.c
+++ b/kernel/ptrace.c
@@ -35,9 +35,9 @@ void __ptrace_link(task_t *child, task_t *new_parent)
35 if (child->parent == new_parent) 35 if (child->parent == new_parent)
36 return; 36 return;
37 list_add(&child->ptrace_list, &child->parent->ptrace_children); 37 list_add(&child->ptrace_list, &child->parent->ptrace_children);
38 REMOVE_LINKS(child); 38 remove_parent(child);
39 child->parent = new_parent; 39 child->parent = new_parent;
40 SET_LINKS(child); 40 add_parent(child);
41} 41}
42 42
43/* 43/*
@@ -77,9 +77,9 @@ void __ptrace_unlink(task_t *child)
77 child->ptrace = 0; 77 child->ptrace = 0;
78 if (!list_empty(&child->ptrace_list)) { 78 if (!list_empty(&child->ptrace_list)) {
79 list_del_init(&child->ptrace_list); 79 list_del_init(&child->ptrace_list);
80 REMOVE_LINKS(child); 80 remove_parent(child);
81 child->parent = child->real_parent; 81 child->parent = child->real_parent;
82 SET_LINKS(child); 82 add_parent(child);
83 } 83 }
84 84
85 ptrace_untrace(child); 85 ptrace_untrace(child);