summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorFrancis Dupont <fdupont@isc.org>2020-10-14 16:16:16 +0200
committerFrancis Dupont <fdupont@isc.org>2020-10-14 16:16:16 +0200
commit4b705d0d1dc37f3e2be97af99838efcb83b4496f (patch)
tree414cc4bcaf79284dd5e776feca37241900ad8672
parent3354013a47fe53f073c520c3c486ab9b7ff53601 (diff)
downloadisc-dhcp-4b705d0d1dc37f3e2be97af99838efcb83b4496f.tar.gz
Added cancel timeouts
-rw-r--r--client/dhclient.c4
1 files changed, 4 insertions, 0 deletions
diff --git a/client/dhclient.c b/client/dhclient.c
index 1a7ac85e..42d098ab 100644
--- a/client/dhclient.c
+++ b/client/dhclient.c
@@ -1302,6 +1302,8 @@ void finish_v6only(cpp)
void *cpp;
{
struct client_state *client = cpp;
+
+ cancel_timeout(finish_v6only, client);
client->state = S_INIT;
state_init(cpp);
}
@@ -1475,6 +1477,7 @@ void dhcpack (packet)
if (v6only_wait > 0) {
log_info("v6 only preferred for %lu.",
(long unsigned)v6only_wait);
+ cancel_timeout(send_request, client);
start_v6only(client, v6only_wait);
return;
}
@@ -2158,6 +2161,7 @@ void dhcpoffer (packet)
if (v6only_wait > 0) {
log_info("%s: v6 only preferred for %lu.", obuf,
(long unsigned)v6only_wait);
+ cancel_timeout(send_discover, client);
start_v6only(client, v6only_wait);
return;
}