Skip to content

Commit

Permalink
dhcp: Fix dhcp_fine_tmr() not to use netif after free
Browse files Browse the repository at this point in the history
Introduced in 86df9f4
  • Loading branch information
freakyxue committed Mar 13, 2023
1 parent 9e62aff commit d5e56d0
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions src/core/ipv4/dhcp.c
Original file line number Diff line number Diff line change
Expand Up @@ -1472,6 +1472,7 @@ dhcp_release_and_stop(struct netif *netif)
dhcp->autoip_coop_state = DHCP_AUTOIP_COOP_STATE_OFF;
}
#endif /* LWIP_DHCP_AUTOIP_COOP */
ESP_LWIP_DHCP_FINE_CLOSE(netif, dhcp);

LWIP_DEBUGF(DHCP_DEBUG | LWIP_DBG_STATE, ("dhcp_release_and_stop(): dhcp state is OFF\n"));
if (dhcp->pcb_allocated != 0) {
Expand Down

0 comments on commit d5e56d0

Please sign in to comment.