diff --git a/CHANGELOG b/CHANGELOG index 3c7b2c6e..41992f31 100644 --- a/CHANGELOG +++ b/CHANGELOG @@ -41,6 +41,9 @@ HISTORY ++ Bugfixes: + 2011-08-24: Simon Goldschmidt + * netif.c: fixed bug #34121 netif_add/netif_set_ipaddr fail on NULL ipaddr + 2011-08-22: Simon Goldschmidt * tcp_out.c: fixed bug #33962 TF_FIN not always set after FIN is sent. (This merely prevents nagle from not transmitting fast after closing.) diff --git a/src/core/netif.c b/src/core/netif.c index 754f1112..6da84234 100644 --- a/src/core/netif.c +++ b/src/core/netif.c @@ -358,7 +358,7 @@ netif_set_ipaddr(struct netif *netif, ip_addr_t *ipaddr) struct tcp_pcb_listen *lpcb; /* address is actually being changed? */ - if ((ip_addr_cmp(ipaddr, &(netif->ip_addr))) == 0) { + if (ipaddr && (ip_addr_cmp(ipaddr, &(netif->ip_addr))) == 0) { /* extern struct tcp_pcb *tcp_active_pcbs; defined by tcp.h */ LWIP_DEBUGF(NETIF_DEBUG | LWIP_DBG_STATE, ("netif_set_ipaddr: netif address being changed\n")); pcb = tcp_active_pcbs;