diff options
author | Felix Fietkau | 2012-09-27 16:22:24 +0200 |
---|---|---|
committer | Denys Vlasenko | 2012-09-27 16:22:24 +0200 |
commit | 1c7a58dfb82ea04c525e0c19f94f2d800dee99e3 (patch) | |
tree | d7526498e61bcbb4d515905379fe1714739364f0 /networking/udhcp/d6_dhcpc.c | |
parent | d1097988825aeec1706d86cc4941d6812735f868 (diff) | |
download | busybox-1c7a58dfb82ea04c525e0c19f94f2d800dee99e3.zip busybox-1c7a58dfb82ea04c525e0c19f94f2d800dee99e3.tar.gz |
udhcpc[6]: allow discover_retries == 0 (infinite)
Signed-off-by: Felix Fietkau <nbd@openwrt.org>
Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>
Diffstat (limited to 'networking/udhcp/d6_dhcpc.c')
-rw-r--r-- | networking/udhcp/d6_dhcpc.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/networking/udhcp/d6_dhcpc.c b/networking/udhcp/d6_dhcpc.c index dda4a91..c44220b 100644 --- a/networking/udhcp/d6_dhcpc.c +++ b/networking/udhcp/d6_dhcpc.c @@ -1111,7 +1111,7 @@ int udhcpc6_main(int argc UNUSED_PARAM, char **argv) switch (state) { case INIT_SELECTING: - if (packet_num < discover_retries) { + if (!discover_retries || packet_num < discover_retries) { if (packet_num == 0) xid = random_xid(); /* multicast */ @@ -1140,7 +1140,7 @@ int udhcpc6_main(int argc UNUSED_PARAM, char **argv) packet_num = 0; continue; case REQUESTING: - if (packet_num < discover_retries) { + if (!discover_retries || packet_num < discover_retries) { /* send multicast select packet */ send_d6_select(xid); timeout = discover_timeout; |