From 3447ea90d74b5cedc84ae2eb4d74cfe16e966017 Mon Sep 17 00:00:00 2001 From: Justin Hibbits Date: Fri, 9 Aug 2019 02:20:26 +0000 Subject: [PATCH] autofs: Fix autounmountd's printing of mount time. time_t should be printed as intmax_t. Even though duration should be short, the correct way to print is intmax_t, not long. Reported by: ian,imp --- usr.sbin/autofs/autounmountd.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/usr.sbin/autofs/autounmountd.c b/usr.sbin/autofs/autounmountd.c index 6f1c0b856f98..25c29e739380 100644 --- a/usr.sbin/autofs/autounmountd.c +++ b/usr.sbin/autofs/autounmountd.c @@ -196,9 +196,9 @@ expire_automounted(time_t expiration_time) if (mounted_for < expiration_time) { log_debugx("skipping %s (FSID:%d:%d), mounted " - "for %ld seconds", af->af_mountpoint, + "for %jd seconds", af->af_mountpoint, af->af_fsid.val[0], af->af_fsid.val[1], - (long)mounted_for); + (intmax_t)mounted_for); if (mounted_for > mounted_max) mounted_max = mounted_for;