Re: [PATCH v2] Make PTRACE_SEIZE set ptrace options specified in 'data' parameter

From: Pedro Alves
Date: Thu Sep 08 2011 - 01:01:49 EST


On Wednesday 07 September 2011 22:40:31, Denys Vlasenko wrote:
> Make PTRACE_SEIZE set ptrace options specified in 'data' parameter

(I wonder if it'd be a good idea to be more future proof and pass in
a pointer to a `struct { int my_size; int options; }', so we can
add more things in the future other than option bits, if we need to.)

> This can be used to close a few corner cases in strace where we get
> unwanted racy behavior after attach, but before we have a chance
> to set options (the notorious post-execve SIGTRAP comes to mind),

(irrespective of the patch being a good idea or not)

>From previous discussions, I understood that PTRACE_SEIZE _always_ disables
the post-execve SIGTRAP, so I don't believe that race actually exists.
Or is that not the case?

--
Pedro Alves
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/