Mirror of strace – the linux syscall tracer
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

utime.c 623B

123456789101112131415161718192021222324252627282930313233
  1. /*
  2. * Copyright (c) 2014-2018 The strace developers.
  3. * All rights reserved.
  4. *
  5. * SPDX-License-Identifier: LGPL-2.1-or-later
  6. */
  7. #include "defs.h"
  8. #include DEF_MPERS_TYPE(utimbuf_t)
  9. #include <utime.h>
  10. typedef struct utimbuf utimbuf_t;
  11. #include MPERS_DEFS
  12. SYS_FUNC(utime)
  13. {
  14. utimbuf_t u;
  15. printpath(tcp, tcp->u_arg[0]);
  16. tprints(", ");
  17. if (!umove_or_printaddr(tcp, tcp->u_arg[1], &u)) {
  18. tprintf("{actime=%lld", (long long) u.actime);
  19. tprints_comment(sprinttime(u.actime));
  20. tprintf(", modtime=%lld", (long long) u.modtime);
  21. tprints_comment(sprinttime(u.modtime));
  22. tprints("}");
  23. }
  24. return RVAL_DECODED;
  25. }