]> git.baikalelectronics.ru Git - kernel.git/commit
ptrace_untrace: fix the SIGNAL_STOP_STOPPED check
authorOleg Nesterov <oleg@redhat.com>
Thu, 2 Apr 2009 23:58:23 +0000 (16:58 -0700)
committerLinus Torvalds <torvalds@linux-foundation.org>
Fri, 3 Apr 2009 02:05:00 +0000 (19:05 -0700)
commit856acec6a2a1dfb7e0b4c48cf9523f57b7ab43cd
tree0216bc3ebccf1c44b86617cd06e7b93510ef5bb8
parent5e39bb01474e32d12cf831835148bbfec7b74c63
ptrace_untrace: fix the SIGNAL_STOP_STOPPED check

This bug is ancient too. ptrace_untrace() must not resume the task
if the group stop in progress, we should set TASK_STOPPED instead.

Unfortunately, we still have problems here:

- if the process/thread was traced, SIGNAL_STOP_STOPPED
  does not necessary means this thread group is stopped.

- ptrace breaks the bookkeeping of ->group_stop_count.

Signed-off-by: Oleg Nesterov <oleg@redhat.com>
Cc: Jerome Marchand <jmarchan@redhat.com>
Cc: Roland McGrath <roland@redhat.com>
Cc: Denys Vlasenko <dvlasenk@redhat.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
kernel/ptrace.c