patch-2.0.29 linux/net/ipv4/ip_input.c

Next file: linux/MAINTAINERS
Previous file: linux/net/ipv4/arp.c
Back to the patch index
Back to the overall index

diff -u --recursive --new-file v2.0.28/linux/net/ipv4/ip_input.c linux/net/ipv4/ip_input.c
@@ -302,8 +302,10 @@
 	 */
 
 #ifdef CONFIG_NET_ALIAS
-	if (iph->daddr != skb->dev->pa_addr && net_alias_has(skb->dev)) 
-		skb->dev = dev = net_alias_dev_rcv_sel32(skb->dev, AF_INET, iph->saddr, iph->daddr);
+	if (iph->daddr != skb->dev->pa_addr && net_alias_has(skb->dev)) {
+		if (ip_chk_addr(iph->daddr) == IS_MYADDR)
+			skb->dev = dev = net_alias_dev_rcv_sel32(skb->dev, AF_INET, iph->saddr, iph->daddr);
+	}
 #endif
 
 	if (iph->ihl > 5) 


FUNET's LINUX-ADM group, linux-adm@nic.funet.fi
TCL-scripts by Sam Shen, slshen@lbl.gov