Skip to content

Commit

Permalink
DHCP6: lastlease behavior after Confim non-response
Browse files Browse the repository at this point in the history
If lastlease is enabled, and dhcpcd is unable to confirm its prior
lease, after timeout, don't continue to solicit. Confine lastlease
behavior to only the CONFIRM state.
  • Loading branch information
Jon Franklin committed Oct 17, 2024
1 parent d97fe02 commit 6137c44
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion src/dhcp6.c
Original file line number Diff line number Diff line change
Expand Up @@ -1760,8 +1760,9 @@ dhcp6_fail(struct interface *ifp, bool drop)
dhcp_unlink(ifp->ctx, state->leasefile);
dhcp6_addrequestedaddrs(ifp);
eloop_timeout_delete(ifp->ctx->eloop, NULL, ifp);
} else if (state->recv && ifp->options->options & DHCPCD_LASTLEASE) {
} else if (state->state == DH6S_CONFIRM && ifp->options->options & DHCPCD_LASTLEASE) {
dhcp6_bind(ifp, NULL, NULL);
return;
} else if (state->new) {
script_runreason(ifp, "TIMEOUT6");
// We need to keep the expire timeout alive
Expand Down

0 comments on commit 6137c44

Please sign in to comment.