From 090131022666e17d05492c4172ceec6b93a72873 Mon Sep 17 00:00:00 2001 From: Joachim Wiberg Date: Sun, 21 Feb 2021 11:47:42 +0100 Subject: [PATCH] Load or reload timezone data on init/SIGHUP This should fix any lingering issues with logging with the wrong timezone at boot. As long as syslogd gets HUP'ed after setting the new timezone. Improvements to this welcome, of course. Signed-off-by: Joachim Wiberg --- src/syslogd.c | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/src/syslogd.c b/src/syslogd.c index b1620de..a212191 100644 --- a/src/syslogd.c +++ b/src/syslogd.c @@ -2280,6 +2280,11 @@ static void init(void) } } + /* + * Load / reload timezone data (in case it changed) + */ + tzset(); + /* * Read configuration file(s) */