From: Zbigniew Jędrzejewski-Szmek Date: Tue, 12 Jan 2016 22:42:06 +0000 (-0500) Subject: sd-device: initialize variables to avoid warning X-Git-Tag: v229~127^2~10 X-Git-Url: http://git.ipfire.org/gitweb.cgi?a=commitdiff_plain;h=97c94b9865c239a849cf9870122afd1e9332cf03;p=thirdparty%2Fsystemd.git sd-device: initialize variables to avoid warning The code is correct, assuming that the kernel does not feed us garbled data. Let's initialize those variables to avoid the warning anyway. --- diff --git a/src/libsystemd/sd-device/sd-device.c b/src/libsystemd/sd-device/sd-device.c index f44054a7b52..9633e46ce08 100644 --- a/src/libsystemd/sd-device/sd-device.c +++ b/src/libsystemd/sd-device/sd-device.c @@ -494,7 +494,7 @@ static int handle_uevent_line(sd_device *device, const char *key, const char *va int device_read_uevent_file(sd_device *device) { _cleanup_free_ char *uevent = NULL; - const char *syspath, *key, *value, *major = NULL, *minor = NULL; + const char *syspath, *key = NULL, *value = NULL, *major = NULL, *minor = NULL; char *path; size_t uevent_len; unsigned i;