]> granicus.if.org Git - strace/blobdiff - aio.c
Robustify mpers.awk against invalid input
[strace] / aio.c
diff --git a/aio.c b/aio.c
index e9d36e3ce515540c79dabc15a76239a8e16aad4b..1cbd533a051a38bf70193ecfea1b87ed3dea29cb 100644 (file)
--- a/aio.c
+++ b/aio.c
@@ -244,7 +244,14 @@ SYS_FUNC(io_getevents)
                        tprints("], ");
                }
 
+               /*
+                * Since the timeout parameter is read by the kernel
+                * on entering syscall, it has to be decoded the same way
+                * whether the syscall has failed or not.
+                */
+               temporarily_clear_syserror(tcp);
                print_timespec(tcp, tcp->u_arg[4]);
+               restore_cleared_syserror(tcp);
        }
        return 0;
 }