From: Paul Floyd Date: Sun, 20 Jul 2025 17:08:46 +0000 (+0200) Subject: FreeBSD compiler warnings X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=4832fda1122a8919eb70f97dc7b0ad67d14db618;p=thirdparty%2Fvalgrind.git FreeBSD compiler warnings Fix a few warnings that I now get with clang 19 on FreeBSD 15. --- diff --git a/coregrind/m_syswrap/syswrap-freebsd.c b/coregrind/m_syswrap/syswrap-freebsd.c index df223a2a0..ac371e125 100644 --- a/coregrind/m_syswrap/syswrap-freebsd.c +++ b/coregrind/m_syswrap/syswrap-freebsd.c @@ -3730,7 +3730,7 @@ PRE(sys_kenv) default: if (VG_(clo_verbosity) >= 1) { VG_(umsg)("Warning: bad or unimplemented kenv action: %" FMT_REGWORD "d\n", - ARG1); + SARG1); } break; } @@ -7087,7 +7087,7 @@ POST(sys_getrlimitusage) // int fchroot(int fd); PRE(sys_fchroot) { - PRINT("sys_fchroot(%" FMT_REGWORD "d)", ARG1); + PRINT("sys_fchroot(%" FMT_REGWORD "d)", SARG1); PRE_REG_READ1(int, "fchroot", int, fd); /* Be strict. */ @@ -7099,7 +7099,7 @@ PRE(sys_fchroot) // int setcred(u_int flags, const struct setcred *wcred, size_t size); PRE(sys_setcred) { - PRINT("sys_setcred(%" FMT_REGWORD "d, %#" FMT_REGWORD "x, %" FMT_REGWORD "u)", ARG1, ARG2, ARG3); + PRINT("sys_setcred(%" FMT_REGWORD "u, %#" FMT_REGWORD "x, %" FMT_REGWORD "u)", ARG1, ARG2, ARG3); PRE_REG_READ3(int, "setcred", u_int, flags, const struct setcred*, wcred, size_t, size); PRE_MEM_READ("setcred(wcred)", ARG2, sizeof(struct vki_setcred)); }