mirror of
https://github.com/edk2-porting/linux-next.git
synced 2024-11-20 16:46:23 +08:00
igmp: Avoid zero delay when receiving odd mixture of IGMP queries
Commit 5b7c840667
('ipv4: correct IGMP
behavior on v3 query during v2-compatibility mode') added yet another
case for query parsing, which can result in max_delay = 0. Substitute
a value of 1, as in the usual v3 case.
Reported-by: Simon McVittie <smcv@debian.org>
References: http://bugs.debian.org/654876
Signed-off-by: Ben Hutchings <ben@decadent.org.uk>
Signed-off-by: David S. Miller <davem@davemloft.net>
This commit is contained in:
parent
e5686ad82c
commit
a8c1f65c79
@ -880,6 +880,8 @@ static void igmp_heard_query(struct in_device *in_dev, struct sk_buff *skb,
|
|||||||
* to be intended in a v3 query.
|
* to be intended in a v3 query.
|
||||||
*/
|
*/
|
||||||
max_delay = IGMPV3_MRC(ih3->code)*(HZ/IGMP_TIMER_SCALE);
|
max_delay = IGMPV3_MRC(ih3->code)*(HZ/IGMP_TIMER_SCALE);
|
||||||
|
if (!max_delay)
|
||||||
|
max_delay = 1; /* can't mod w/ 0 */
|
||||||
} else { /* v3 */
|
} else { /* v3 */
|
||||||
if (!pskb_may_pull(skb, sizeof(struct igmpv3_query)))
|
if (!pskb_may_pull(skb, sizeof(struct igmpv3_query)))
|
||||||
return;
|
return;
|
||||||
|
Loading…
Reference in New Issue
Block a user