From 4813a5210f6fb979d8f7a592f71a2f9c4d3db179 Mon Sep 17 00:00:00 2001 From: Sami Kerola Date: Sat, 9 Feb 2019 09:34:52 +0000 Subject: various: fix 'uninitialized when used' warnings [clang] This change fixes "warning: variable 'var' may be uninitialized when used here [-Wconditional-uninitialized]" warnings reported in various files. Signed-off-by: Sami Kerola --- sys-utils/hwclock.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'sys-utils/hwclock.c') diff --git a/sys-utils/hwclock.c b/sys-utils/hwclock.c index d9acbaf7d..5f4c014fc 100644 --- a/sys-utils/hwclock.c +++ b/sys-utils/hwclock.c @@ -954,7 +954,7 @@ manipulate_clock(const struct hwclock_control *ctl, const time_t set_time, const struct timeval startup_time, struct adjtime *adjtime) { /* The time at which we read the Hardware Clock */ - struct timeval read_time; + struct timeval read_time = { 0 }; /* * The Hardware Clock gives us a valid time, or at * least something close enough to fool mktime(). -- cgit v1.2.3-55-g7522