On Fri, Mar 11, 2011 at 02:02:15AM +0300, Dmitry V. Levin wrote: > P.S. While testing these changes, I've spotted a bug. > Try to run "cat > /dev/null & strace -p $!", it looks like some > stop signals are not actually delivered to traced processes.
I believe this is a kernel bug. The first SIGCHLD informs tracer about a signal being sent to its tracee (si_code is CLD_TRAPPED). The second SIGCHLD informs tracer that its tracee is being stopped (si_code is CLD_STOPPED). A PTRACE_SYSCALL issued after CLD_STOPPED results to the tracee being continued instead of stopped. And without that PTRACE_SYSCALL, the tracee remains trapped until its tracer detached. That is, the tracee remains trapped in both cases, and there seems to be no way to actually place it in that stopped state reported by kernel. As result, no job control will ever work under ptrace. -- ldv
pgp1gaX5ZMMx9.pgp
Description: PGP signature
------------------------------------------------------------------------------ Colocation vs. Managed Hosting A question and answer guide to determining the best fit for your organization - today and in the future. http://p.sf.net/sfu/internap-sfd2d
_______________________________________________ Strace-devel mailing list [email protected] https://lists.sourceforge.net/lists/listinfo/strace-devel
