Re: [PATCH 70] move event 8 into syscall_code()

2009-10-08 Thread Oleg Nesterov
On 10/07, Roland McGrath wrote: void set_stop_code(struct ptrace_context *ctx, int event) { ctx-stop_code = (event 8) | SIGTRAP; } void set_syscall_code(struct ptrace_context *ctx, int event) { set_stop_code(ctx, event);

Re: [PATCH 70] move event 8 into syscall_code()

2009-10-07 Thread Roland McGrath
Make it something like: static inline void set_stop_code(struct ptrace_context *ctx, int event) { ctx-stop_code = (event 8) | SIGTRAP | (event = PTRACE_EVENT_SYSCALL_ENTRY (ctx-options PTRACE_O_TRACESYSGOOD) ?

Re: [PATCH 70] move event 8 into syscall_code()

2009-10-07 Thread Oleg Nesterov
On 10/07, Roland McGrath wrote: Make it something like: static inline void set_stop_code(struct ptrace_context *ctx, int event) { ctx-stop_code = (event 8) | SIGTRAP | (event = PTRACE_EVENT_SYSCALL_ENTRY (ctx-options

Re: [PATCH 70] move event 8 into syscall_code()

2009-10-07 Thread Roland McGrath
void set_stop_code(struct ptrace_context *ctx, int event) { ctx-stop_code = (event 8) | SIGTRAP; } void set_syscall_code(struct ptrace_context *ctx, int event) { set_stop_code(ctx, event); if (PTRACE_O_TRACESYSGOOD)