chiark / gitweb /
sd-dhcp6-client: make gcc happy
authorTom Gundersen <teg@jklm.no>
Sat, 12 Jul 2014 21:07:33 +0000 (23:07 +0200)
committerTom Gundersen <teg@jklm.no>
Mon, 14 Jul 2014 14:49:41 +0000 (16:49 +0200)
It complains about {max,init}_retransmit_time possibly being
uninitialized. It is wrong, but let's just initialize it.

src/libsystemd-network/sd-dhcp6-client.c

index a83778e..4f60578 100644 (file)
@@ -387,7 +387,7 @@ static int client_timeout_resend(sd_event_source *s, uint64_t usec,
                                  void *userdata) {
         int r = 0;
         sd_dhcp6_client *client = userdata;
-        usec_t time_now, init_retransmit_time, max_retransmit_time;
+        usec_t time_now, init_retransmit_time = 0, max_retransmit_time = 0;
         usec_t max_retransmit_duration = 0;
         uint8_t max_retransmit_count = 0;
         char time_string[FORMAT_TIMESPAN_MAX];