From 6f03f3d85c7345a1baf4c4e8a03d27688d38ed4f Mon Sep 17 00:00:00 2001 From: Edward Tomasz Napierala Date: Sun, 19 Feb 2017 16:59:00 +0000 Subject: [PATCH] Make savecore(8) output nicer by specifying the maximum field width instead of minimum one (precision instead of width). MFC after: 2 weeks Sponsored by: DARPA, AFRL --- sbin/savecore/savecore.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/sbin/savecore/savecore.c b/sbin/savecore/savecore.c index a85adc62e9e..15738302494 100644 --- a/sbin/savecore/savecore.c +++ b/sbin/savecore/savecore.c @@ -651,7 +651,7 @@ DoFile(const char *savedir, const char *device) } if (kdhl.panicstring[0] != '\0') - syslog(LOG_ALERT, "reboot after panic: %*s", + syslog(LOG_ALERT, "reboot after panic: %.*s", (int)sizeof(kdhl.panicstring), kdhl.panicstring); else syslog(LOG_ALERT, "reboot");