Re: [PATCH 63] convert ptrace_getsiginfo() to use ptrace_rw_siginfo()

2009-10-07 Thread Roland McGrath
+ if (context-siginfo) + return ptrace_rw_siginfo(tracee, context, info, false); - return error; + memset(info, 0, sizeof(*info)); + info-si_signo = SIGTRAP; + info-si_code = context-ev_code; // XXX: ev_code was already cleared!!! + info-si_pid =

Re: [PATCH 63] convert ptrace_getsiginfo() to use ptrace_rw_siginfo()

2009-10-07 Thread Oleg Nesterov
On 10/07, Roland McGrath wrote: + if (context-siginfo) + return ptrace_rw_siginfo(tracee, context, info, false); - return error; + memset(info, 0, sizeof(*info)); + info-si_signo = SIGTRAP; + info-si_code = context-ev_code; // XXX: ev_code was already cleared!!!

[PATCH 63] convert ptrace_getsiginfo() to use ptrace_rw_siginfo()

2009-10-02 Thread Oleg Nesterov
- Change ptrace_getsiginfo() to use ptrace_rw_siginfo(). - Fix the semantics. We should return EINVAL only if the tracee was stopped. If it didn't report the signal, we fill siginfo like ptrace_notify() did. Note! Currently do_ptrace_notify_stop() clears context-ev_code for debugging