summaryrefslogtreecommitdiff
path: root/sbin
diff options
context:
space:
mode:
authorFlorian Obser <florian@cvs.openbsd.org>2021-07-23 11:56:02 +0000
committerFlorian Obser <florian@cvs.openbsd.org>2021-07-23 11:56:02 +0000
commit861cbdd3459ee4740cf37f27d9316f1f24695494 (patch)
tree1a9bf361b3d124ecba1c849f267aff0f8ed915e5 /sbin
parent9013ab257ed0099e4e1e4a5244a255a8f75b7d37 (diff)
When dhcpleasectl asks to send a new request on an interface we are
probably stuck in some way and the user wants a mostly clean slate. If we already have an IP address transition to state REBOOTING so that we no longer unicast dhcp requests. We will then try to reacquire our lease twice before giving up and transition to INIT and send dhcp discover messages accepting any IP address.
Diffstat (limited to 'sbin')
-rw-r--r--sbin/dhcpleased/engine.c8
1 files changed, 4 insertions, 4 deletions
diff --git a/sbin/dhcpleased/engine.c b/sbin/dhcpleased/engine.c
index 0903c1792d1..20ed7c45da1 100644
--- a/sbin/dhcpleased/engine.c
+++ b/sbin/dhcpleased/engine.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: engine.c,v 1.19 2021/07/18 12:33:41 florian Exp $ */
+/* $OpenBSD: engine.c,v 1.20 2021/07/23 11:56:01 florian Exp $ */
/*
* Copyright (c) 2017, 2021 Florian Obser <florian@openbsd.org>
@@ -322,13 +322,13 @@ engine_dispatch_frontend(int fd, short event, void *bula)
break;
case IF_INIT:
case IF_REQUESTING:
+ state_transition(iface, iface->state);
+ break;
case IF_RENEWING:
case IF_REBINDING:
case IF_REBOOTING:
- state_transition(iface, iface->state);
- break;
case IF_BOUND:
- state_transition(iface, IF_RENEWING);
+ state_transition(iface, IF_REBOOTING);
break;
}
}