[dm-devel] [PATCH 08/11] Reset timezone information on reconfigure

Hannes Reinecke hare at suse.de
Fri Dec 13 12:14:11 UTC 2013


Whenever 'reconfigure' is called we need to re-initialize the
timezone information as it might have been changed in the
meantime.

References: bnc#830511

Signed-off-by: Hannes Reinecke <hare at suse.de>
---
 libmultipath/log.c | 1 +
 multipathd/main.c  | 3 +++
 2 files changed, 4 insertions(+)

diff --git a/libmultipath/log.c b/libmultipath/log.c
index 37c7cd7..74702d8 100644
--- a/libmultipath/log.c
+++ b/libmultipath/log.c
@@ -99,6 +99,7 @@ void log_close (void)
 void log_reset (char *program_name)
 {
 	closelog();
+	tzset();
 	openlog(program_name, 0, LOG_DAEMON);
 }
 
diff --git a/multipathd/main.c b/multipathd/main.c
index 96564f8..1a1aa2d 100644
--- a/multipathd/main.c
+++ b/multipathd/main.c
@@ -1416,6 +1416,9 @@ reconfigure (struct vectors * vecs)
 	vecs->pathvec = NULL;
 	conf = NULL;
 
+	/* Re-read any timezone changes */
+	tzset();
+
 	if (!load_config(DEFAULT_CONFIGFILE, udev)) {
 		conf->verbosity = old->verbosity;
 		conf->daemon = 1;
-- 
1.8.1.4




More information about the dm-devel mailing list