Files
linux-stable-mirror/lib
Andy Shevchenko c2a0862ad4 lib/vsprintf: Check pointer before dereferencing in time_and_date()
[ Upstream commit 372a12bd5d ]

The pointer may be invalid when gets to the printf(). In particular
the time_and_date() dereferencing it in some cases without checking.

Move the check from rtc_str() to time_and_date() to cover all cases.

Fixes: 7daac5b2fd ("lib/vsprintf: Print time64_t in human readable format")
Signed-off-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com>
Reviewed-by: Petr Mladek <pmladek@suse.com>
Link: https://patch.msgid.link/20251110132118.4113976-1-andriy.shevchenko@linux.intel.com
Signed-off-by: Petr Mladek <pmladek@suse.com>
Signed-off-by: Sasha Levin <sashal@kernel.org>
2025-12-18 13:54:57 +01:00
..
2024-07-12 16:39:53 -07:00
2024-07-04 23:43:10 -07:00
2024-09-03 21:15:42 -07:00