]> granicus.if.org Git - strace/blobdiff - times.c
travis: add build environment information to the travis log
[strace] / times.c
diff --git a/times.c b/times.c
index d3f6daf25152f4e4a83987c4364f4c02cc77141e..1ba0168455b8528536504ca54d4f0d60501b2695 100644 (file)
--- a/times.c
+++ b/times.c
@@ -6,6 +6,7 @@
  * Copyright (c) 2012 H.J. Lu <hongjiu.lu@intel.com>
  * Copyright (c) 2015 Elvira Khabirova <lineprinter0@gmail.com>
  * Copyright (c) 2015 Dmitry V. Levin <ldv@altlinux.org>
+ * Copyright (c) 2015-2017 The strace developers.
  * All rights reserved.
  *
  * Redistribution and use in source and binary forms, with or without
@@ -46,17 +47,12 @@ SYS_FUNC(times)
 
        if (!umove_or_printaddr(tcp, tcp->u_arg[0], &tbuf)) {
                tprintf("{tms_utime=%llu, tms_stime=%llu, ",
-                       (unsigned long long) tbuf.tms_utime,
-                       (unsigned long long) tbuf.tms_stime);
+                       zero_extend_signed_to_ull(tbuf.tms_utime),
+                       zero_extend_signed_to_ull(tbuf.tms_stime));
                tprintf("tms_cutime=%llu, tms_cstime=%llu}",
-                       (unsigned long long) tbuf.tms_cutime,
-                       (unsigned long long) tbuf.tms_cstime);
+                       zero_extend_signed_to_ull(tbuf.tms_cutime),
+                       zero_extend_signed_to_ull(tbuf.tms_cstime));
        }
 
-       return syserror(tcp) ? RVAL_DECIMAL :
-#if defined(RVAL_LUDECIMAL) && !defined(IN_MPERS)
-                              RVAL_LUDECIMAL;
-#else
-                              RVAL_UDECIMAL;
-#endif
+       return syserror(tcp) ? RVAL_DECIMAL : RVAL_UDECIMAL;
 }