Sent on 2010-10-7 10:31, Wang Chao wrote:
>  internal_fork(struct tcb *tcp)
>  {
> +     if ((ptrace_setoptions
> +         & (PTRACE_O_TRACECLONE | PTRACE_O_TRACEFORK | PTRACE_O_TRACEVFORK))
> +        == (PTRACE_O_TRACECLONE | PTRACE_O_TRACEFORK | PTRACE_O_TRACEVFORK))
> +             return 0;
> +

Sent on 2010-10-5 12:45, Roland McGrath wrote:
> I don't think you want to skip all of internal_fork.
> e.g. I think fork_tcb is still useful.
> 
> I think you just want to conditionalize the setbpt call.
> 

Well, in my opinion, we can skip whole internal_fork call safely
here if PTRACE_SETOPTIONS is in charge. 

Currently, I think TCB_FOLLOWFORK is used to distinguish the
new forked child and original parent at exit point of fork
syscall. While using PTRACE_SETOPTIONS, new child will be
handled when we revice PTRACE_EVENT_* status and I think no
more work will be needed in internal_fork.

I'm sorry if i don't understand correctly.

Thanks,
Wang Chao


------------------------------------------------------------------------------
Beautiful is writing same markup. Internet Explorer 9 supports
standards for HTML5, CSS3, SVG 1.1,  ECMAScript5, and DOM L2 & L3.
Spend less time writing and  rewriting code and more time creating great
experiences on the web. Be a part of the beta today.
http://p.sf.net/sfu/beautyoftheweb
_______________________________________________
Strace-devel mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/strace-devel

Reply via email to