On 10/06, Jan Kratochvil wrote: > > On Tue, 06 Oct 2009 22:05:16 +0200, Oleg Nesterov wrote: > > For example, the tracee reports PTRACE_EVENT_EXEC and stops. In this > > case SIGNR has no effect after PTRACE_CONT/DETACH/etc. > > > > SIGNR does not ignored after the tracee reported syscall entry/exit or > > signal. > > OK, if only such exceptional cases as PTRACE_EVENT_EXEC that should not matter > I think.
Also PTRACE_EVENT_FORK and friends. > It should work also for PTRACE_SINGLESTEP. Heh. Yes, but with one exception. - the tracee has a hanlder for, say, SIGHUP - the tracee deques SIGHUP, reports to the tracer, and stops. - the tracer does ptrace(SINGLESTEP, SIGHUP) // it could use another signr, this works. // but the tracer must have a handler or // everething is OK. - the tracee delivers SIGHUP to itself, handle_signal() notices TIF_SINGLESTEP and calls ptrace_notify(). Now, the tracee reports SIGTRAP, but the next time the tracer does ptrace(WHATEVER, SIGNR) SIGNR will be ignored. Oleg.