The branch main has been updated by imp: URL: https://cgit.FreeBSD.org/src/commit/?id=00b0498051de59c9014fe2cf239b28c3e4bd469c
commit 00b0498051de59c9014fe2cf239b28c3e4bd469c Author: John F. Carr <j...@mit.edu> AuthorDate: 2024-04-22 19:13:44 +0000 Commit: Warner Losh <i...@freebsd.org> CommitDate: 2024-09-22 13:26:46 +0000 Fix xo_emit format string for percentages The "%lld" format string was used with a value of type long. See https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=278532. Reviewed by: imp, mmel Pull Request: https://github.com/freebsd/freebsd-src/pull/1344 --- usr.bin/vmstat/vmstat.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/usr.bin/vmstat/vmstat.c b/usr.bin/vmstat/vmstat.c index e7790ad6e2f6..1d0eb4c9283f 100644 --- a/usr.bin/vmstat/vmstat.c +++ b/usr.bin/vmstat/vmstat.c @@ -1105,7 +1105,7 @@ percent(const char *name, long pctv, int *over) { char fmt[64]; - snprintf(fmt, sizeof(fmt), " {:%s/%%%ulld/%%lld}", name, + snprintf(fmt, sizeof(fmt), " {:%s/%%%uld/%%ld}", name, (*over && pctv <= 9) ? 1 : 2); xo_emit(fmt, pctv); if (*over && pctv <= 9)