mirror of
https://github.com/lwip-tcpip/lwip.git
synced 2025-01-26 09:35:23 +00:00
23/02/2003 - Kieran Mansley - kieranm@gtemail.net
* Applied patch #2679 * Adds check to line 75 for NETIF_FLAG_BROADCAST
This commit is contained in:
parent
5c7189124c
commit
3a784509df
@ -72,7 +72,8 @@ icmp_input(struct pbuf *p, struct netif *inp)
|
|||||||
code = *(((u8_t *)p->payload)+1);
|
code = *(((u8_t *)p->payload)+1);
|
||||||
switch (type) {
|
switch (type) {
|
||||||
case ICMP_ECHO:
|
case ICMP_ECHO:
|
||||||
if (ip_addr_isbroadcast(&iphdr->dest, &inp->netmask) ||
|
if (((inp->flags & NETIF_FLAG_BROADCAST) &&
|
||||||
|
ip_addr_isbroadcast(&iphdr->dest, &inp->netmask)) ||
|
||||||
ip_addr_ismulticast(&iphdr->dest)) {
|
ip_addr_ismulticast(&iphdr->dest)) {
|
||||||
LWIP_DEBUGF(ICMP_DEBUG, ("Smurf.\n"));
|
LWIP_DEBUGF(ICMP_DEBUG, ("Smurf.\n"));
|
||||||
ICMP_STATS_INC(icmp.err);
|
ICMP_STATS_INC(icmp.err);
|
||||||
|
Loading…
x
Reference in New Issue
Block a user