diff options
-rw-r--r-- | net/ipv4/igmp.c | 5 | ||||
-rw-r--r-- | net/ipv6/mcast.c | 5 |
2 files changed, 9 insertions, 1 deletions
diff --git a/net/ipv4/igmp.c b/net/ipv4/igmp.c index c04607b49212..4a195c724f01 100644 --- a/net/ipv4/igmp.c +++ b/net/ipv4/igmp.c | |||
@@ -897,7 +897,10 @@ int igmp_rcv(struct sk_buff *skb) | |||
897 | /* Is it our report looped back? */ | 897 | /* Is it our report looped back? */ |
898 | if (((struct rtable*)skb->dst)->fl.iif == 0) | 898 | if (((struct rtable*)skb->dst)->fl.iif == 0) |
899 | break; | 899 | break; |
900 | igmp_heard_report(in_dev, ih->group); | 900 | /* don't rely on MC router hearing unicast reports */ |
901 | if (skb->pkt_type == PACKET_MULTICAST || | ||
902 | skb->pkt_type == PACKET_BROADCAST) | ||
903 | igmp_heard_report(in_dev, ih->group); | ||
901 | break; | 904 | break; |
902 | case IGMP_PIM: | 905 | case IGMP_PIM: |
903 | #ifdef CONFIG_IP_PIMSM_V1 | 906 | #ifdef CONFIG_IP_PIMSM_V1 |
diff --git a/net/ipv6/mcast.c b/net/ipv6/mcast.c index f15e04ad026e..fd939da090c4 100644 --- a/net/ipv6/mcast.c +++ b/net/ipv6/mcast.c | |||
@@ -1231,6 +1231,11 @@ int igmp6_event_report(struct sk_buff *skb) | |||
1231 | if (skb->pkt_type == PACKET_LOOPBACK) | 1231 | if (skb->pkt_type == PACKET_LOOPBACK) |
1232 | return 0; | 1232 | return 0; |
1233 | 1233 | ||
1234 | /* send our report if the MC router may not have heard this report */ | ||
1235 | if (skb->pkt_type != PACKET_MULTICAST && | ||
1236 | skb->pkt_type != PACKET_BROADCAST) | ||
1237 | return 0; | ||
1238 | |||
1234 | if (!pskb_may_pull(skb, sizeof(struct in6_addr))) | 1239 | if (!pskb_may_pull(skb, sizeof(struct in6_addr))) |
1235 | return -EINVAL; | 1240 | return -EINVAL; |
1236 | 1241 | ||