]> git.ipfire.org Git - thirdparty/valgrind.git/commitdiff
FreeBSD syswrap: utimensat timespec can be NULL
authorPaul Floyd <pjfloyd@wanadoo.fr>
Wed, 14 Jan 2026 08:00:07 +0000 (09:00 +0100)
committerPaul Floyd <pjfloyd@wanadoo.fr>
Wed, 14 Jan 2026 08:00:07 +0000 (09:00 +0100)
coregrind/m_syswrap/syswrap-freebsd.c

index e1c1dcc14ea0d6731732b0bfb63907226693f12c..2870b4eb723cd885e45edac4a51e4fbcb012f9f3 100644 (file)
@@ -6281,7 +6281,8 @@ PRE(sys_utimensat)
                  int, flag);
    ML_(fd_at_check_allowed)(SARG1, (const HChar*)ARG2, "utimensat", tid, status);
    PRE_MEM_RASCIIZ("utimensat(path)", ARG2);
-   PRE_MEM_READ("utimensat(times)", ARG3, 2*sizeof(struct vki_timespec));
+   if (ARG3)
+      PRE_MEM_READ("utimensat(times)", ARG3, 2*sizeof(struct vki_timespec));
 }
 
 // SYS_fdatasync  550