diff mbox series

[pseudo,24/34] pseudo_util: Fix the date format in the event log dump

Message ID 1794370862-30908-25-git-send-email-mark.hatle@kernel.crashing.org
State New
Headers show
Series Various fixes | expand

Commit Message

Mark Hatle Nov. 11, 2026, 4:20 a.m. UTC
From: Mark Hatle <mark.hatle@amd.com>

pseudo_evlog_dump() formatted the first and last entry times with
"%Y-%M-%D", which prints the minutes and a date in place of the
month and day.  Use "%Y-%m-%d" instead.

AI-Generated: Uses GitHub Copilot
Signed-off-by: Mark Hatle <mark.hatle@amd.com>
---
 pseudo_util.c | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)
diff mbox series

Patch

diff --git a/pseudo_util.c b/pseudo_util.c
index 1eb90d5..e0d7306 100644
--- a/pseudo_util.c
+++ b/pseudo_util.c
@@ -560,8 +560,8 @@  pseudo_evlog_dump(void) {
 	}
 	localtime_r(&first, &first_tm);
 	localtime_r(&last, &last_tm);
-	strftime(firstdate, 64, "%Y-%M-%D %H:%M:%S", &first_tm);
-	strftime(lastdate, 64, "%Y-%M-%D %H:%M:%S", &last_tm);
+	strftime(firstdate, 64, "%Y-%m-%d %H:%M:%S", &first_tm);
+	strftime(lastdate, 64, "%Y-%m-%d %H:%M:%S", &last_tm);
 
 	len = snprintf(scratch, 256, "event log for pid %d [%d entries]\n",
 		getpid(), entries);