minor derivative to reduce compiler warnings and tag read-only parameters as const.

Dependents:   EthernetInterface

Fork of lwip by mbed official

Revision:
11:4b3f6f8b92d2
Parent:
0:51ac1d130fd4
--- a/core/ipv4/ip.c	Thu May 30 17:11:58 2013 +0100
+++ b/core/ipv4/ip.c	Mon Aug 19 18:37:54 2013 +0300
@@ -400,7 +400,7 @@
   /* broadcast or multicast packet source address? Compliant with RFC 1122: 3.2.1.3 */
 #if IP_ACCEPT_LINK_LAYER_ADDRESSING
   /* DHCP servers need 0.0.0.0 to be allowed as source address (RFC 1.1.2.2: 3.2.1.3/a) */
-  if (check_ip_src && !ip_addr_isany(&current_iphdr_src))
+  if (check_ip_src && current_iphdr_src.addr != IPADDR_ANY)
 #endif /* IP_ACCEPT_LINK_LAYER_ADDRESSING */
   {  if ((ip_addr_isbroadcast(&current_iphdr_src, inp)) ||
          (ip_addr_ismulticast(&current_iphdr_src))) {