aboutsummaryrefslogtreecommitdiff
path: root/kernel/signal.c
diff options
context:
space:
mode:
authorPavel Machek <pavel@suse.cz>2006-03-31 02:30:06 -0800
committerGreg Kroah-Hartman <gregkh@suse.de>2006-04-17 13:16:06 -0700
commit6b2467e45179a336f1e5b70d2b2ae1fe89a00133 (patch)
tree89aad214002493c08f0ca25646361e1d8443b40e /kernel/signal.c
parentdea8e11ab727c4c7d75d391354eab355cd74e95a (diff)
[PATCH] Fix suspend with traced tasks
strace /bin/bash misbehaves after resume; this fixes it. (akpm: it's scary calling refrigerator() in state TASK_TRACED, but it seems to do the right thing). Signed-off-by: Pavel Machek <pavel@suse.cz> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
Diffstat (limited to 'kernel/signal.c')
-rw-r--r--kernel/signal.c1
1 files changed, 1 insertions, 0 deletions
diff --git a/kernel/signal.c b/kernel/signal.c
index bc8f80b3fdb..54acb53e4b3 100644
--- a/kernel/signal.c
+++ b/kernel/signal.c
@@ -1688,6 +1688,7 @@ static void ptrace_stop(int exit_code, int nostop_code, siginfo_t *info)
/* Let the debugger run. */
set_current_state(TASK_TRACED);
spin_unlock_irq(&current->sighand->siglock);
+ try_to_freeze();
read_lock(&tasklist_lock);
if (likely(current->ptrace & PT_PTRACED) &&
likely(current->parent != current->real_parent ||