]> granicus.if.org Git - strace/commit
Fix -z display.
authorDenys Vlasenko <dvlasenk@redhat.com>
Mon, 22 Aug 2011 00:06:35 +0000 (02:06 +0200)
committerDenys Vlasenko <dvlasenk@redhat.com>
Tue, 23 Aug 2011 10:53:02 +0000 (12:53 +0200)
commit3b73881a0dc6b0e084e0f78e70904123fa305d8b
tree905d79129f9f1d9ead66dce057a686bb6dfe5e98
parentb88f96129f8ebc064d490c8c161bcbc925d938c8
Fix -z display.

Before this patch, the following:
    open("qwerty", O_RDONLY)    = -1 ENOENT
    write(2, "wc: qwerty: No such file or dire"..., 38) = 38
was shown totally wrongly with -z:
    open("qwerty", O_RDONLY)    = 38
(yes, that's right, write syscall is lost!)
Now it is shown "less wrongly" as:
    open("qwerty", O_RDONLY <unfinished ...>
    write(2, "wc: qwerty: No such file or dire"..., 38) = 38

* syscall.c (trace_syscall_exiting): Use common TCB_INSYSCALL clearing
via "goto ret". This fixes totally broken display of -z, but even now
it is not working as intended. Add a comment about that.
(trace_syscall_entering): Use common TCB_INSYSCALL setting
via "goto ret".

Signed-off-by: Denys Vlasenko <dvlasenk@redhat.com>
syscall.c