Addition to patch #6721, bug #25575: call autoip_stop in dhcp_stop if in coop-mode

This commit is contained in:
goldsimon 2009-05-02 15:40:39 +00:00
parent 23d7f5425d
commit 9317105c37
2 changed files with 9 additions and 1 deletions

View File

@ -110,7 +110,8 @@ HISTORY
have to set IP_SOF_BROADCAST_RECV=1 in opt.h.
2009-04-28 Simon Goldschmidt, Jakob Stoklund Olesen
* dhcp.c: patch #6721: Some small fixes to DHCP and DHCP/AUTOIP cooperation
* dhcp.c: patch #6721, bugs #25575, #25576: Some small fixes to DHCP and
DHCP/AUTOIP cooperation
2009-04-25 Simon Goldschmidt, Oleg Tyshev
* tcp_out.c: bug #24212: Deadlocked tcp_retransmit due to exceeded pcb->cwnd

View File

@ -1118,6 +1118,13 @@ dhcp_stop(struct netif *netif)
LWIP_DEBUGF(DHCP_DEBUG | LWIP_DBG_TRACE | 3, ("dhcp_stop()\n"));
/* netif is DHCP configured? */
if (dhcp != NULL) {
#if LWIP_DHCP_AUTOIP_COOP
if(dhcp->autoip_coop_state == DHCP_AUTOIP_COOP_STATE_ON) {
autoip_stop(netif);
dhcp->autoip_coop_state = DHCP_AUTOIP_COOP_STATE_OFF;
}
#endif /* LWIP_DHCP_AUTOIP_COOP */
if (dhcp->pcb != NULL) {
udp_remove(dhcp->pcb);
dhcp->pcb = NULL;