From: Daniel Jacobowitz <dan@debian.org>
To: linux-kernel@vger.kernel.org, torvalds@transmeta.com
Subject: Ptrace updates: CLONE_PTRACE should use force_sig_specific [3/5]
Date: Thu, 6 Feb 2003 17:42:19 -0500 [thread overview]
Message-ID: <20030206224219.GC22762@nevyn.them.org> (raw)
In-Reply-To: <20030206223924.GA22688@nevyn.them.org>
Right now, CLONE_PTRACE uses send_sig(SIGSTOP, p, 1). If you use
CLONE_THREAD | CLONE_PTRACE, though, this SIGSTOP gets broadcast to the
entire thread group. That's not what was intended; we only want the one
new thread to stop. Fixed like so.
# --------------------------------------------
# 03/02/04 drow@nevyn.them.org 1.959
# Use force_sig_specific to send SIGSTOP to newly-created CLONE_PTRACE processes.
# --------------------------------------------
diff -Nru a/kernel/fork.c b/kernel/fork.c
--- a/kernel/fork.c Thu Feb 6 16:57:32 2003
+++ b/kernel/fork.c Thu Feb 6 16:57:32 2003
@@ -1036,7 +1036,7 @@
}
if (p->ptrace & PT_PTRACED)
- send_sig(SIGSTOP, p, 1);
+ force_sig_specific(SIGSTOP, p);
wake_up_forked_process(p); /* do this last */
++total_forks;
--
Daniel Jacobowitz
MontaVista Software Debian GNU/Linux Developer
next prev parent reply other threads:[~2003-02-06 22:32 UTC|newest]
Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top
2003-02-06 22:39 Ptrace updates [0/5] Daniel Jacobowitz
2003-02-06 22:40 ` Ptrace updates: has_stopped_jobs [1/5] Daniel Jacobowitz
2003-02-06 22:41 ` Ptrace updates: PTRACE_GETSIGINFO [2/5] Daniel Jacobowitz
2003-02-06 22:42 ` Daniel Jacobowitz [this message]
2003-02-06 22:42 ` Ptrace updates: event tracing for vfork finish and process exit [4/5] Daniel Jacobowitz
2003-02-06 22:43 ` Ptrace updates: Prevent zombies when debugging LinuxThreads apps [5/5] Daniel Jacobowitz
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20030206224219.GC22762@nevyn.them.org \
--to=dan@debian.org \
--cc=linux-kernel@vger.kernel.org \
--cc=torvalds@transmeta.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.