From 8e830e72e3146491fe5cb0637f4a96226b1ac1f1 Mon Sep 17 00:00:00 2001 From: Roy Marples Date: Wed, 22 Jan 2020 16:21:12 +0000 Subject: [PATCH] DHCP: Take interface reference on Address Defend failure As the astate could be freed on dropping the DHCP state. --- src/dhcp.c | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/src/dhcp.c b/src/dhcp.c index ccd39b99..b9757be0 100644 --- a/src/dhcp.c +++ b/src/dhcp.c @@ -2335,9 +2335,10 @@ dhcp_message_new(struct bootp **bootp, static void dhcp_arp_defend_failed(struct arp_state *astate) { + struct interface *ifp = astate->iface; - dhcp_drop(astate->iface, "EXPIRED"); - dhcp_start1(astate->iface); + dhcp_drop(ifp, "EXPIRED"); + dhcp_start1(ifp); } #endif -- 2.47.2