> Changelog: Format nits:
> 2008-12-08 Denys Vlasenko <[EMAIL PROTECTED]> Blank line here. > * defs.h (handle_ptrace_err): New function Use proper punctuation on the sentence. "New function" applies to where something is defined. defs.h just declares it. > * strace.c: move process death handling in a static function > * strace.c, util.c: Call it instead of perror Use proper capitalization and punctuation. These must cite the affected functions specifically. Follow the style you see used in the file. Now, to the patch itself. Firstly, the cleaner way to organize the source is not handle_ptrace_err, but to write a wrapper used for all calls to ptrace. That can do the call and the error checking in one place, making all the callers simpler. Second, I don't think handle_death is a good idea. That is, don't do a special-case wait. Let the normal wait logic handle the death report when it comes. What I think we want is to record the errno in a new tcb field and go back to the normal loop. Possibly it could immediately print something new like "<unavailable>", but probably better instead to have a check for a saved ptrace error in the main loop after the WIFSIGNALED and WIFEXITED cases. If we get further and there is a saved ptrace error, then print the "<unavailable>" or perhaps something with the strerror string. (Then clear the saved error record, since we've reported it.) In the WIFSIGNALED and WIFEXITED cases, the error is not worth mentioning and the usual logic will print "<unfinished>" before the death details. Thanks, Roland ------------------------------------------------------------------------------ SF.Net email is Sponsored by MIX09, March 18-20, 2009 in Las Vegas, Nevada. The future of the web can't happen without you. Join us at MIX09 to help pave the way to the Next Web now. Learn more and register at http://ad.doubleclick.net/clk;208669438;13503038;i?http://2009.visitmix.com/ _______________________________________________ Strace-devel mailing list [email protected] https://lists.sourceforge.net/lists/listinfo/strace-devel
