diff options
author | Joe Perches <joe@perches.com> | 2007-12-16 13:45:43 -0800 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2008-01-28 14:58:15 -0800 |
commit | f97c1e0c6ebdb606c97b6cb5e837c6110ac5a961 (patch) | |
tree | 2af3da0114614a127099f9ab2ef706f676faa376 /net/ipv4/ipmr.c | |
parent | 21cf2253ebcf070bc307e0b56d696a2519c75cb4 (diff) | |
download | linux-3.10-f97c1e0c6ebdb606c97b6cb5e837c6110ac5a961.tar.gz linux-3.10-f97c1e0c6ebdb606c97b6cb5e837c6110ac5a961.tar.bz2 linux-3.10-f97c1e0c6ebdb606c97b6cb5e837c6110ac5a961.zip |
[IPV4] net/ipv4: Use ipv4_is_<type>
Signed-off-by: Joe Perches <joe@perches.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'net/ipv4/ipmr.c')
-rw-r--r-- | net/ipv4/ipmr.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/net/ipv4/ipmr.c b/net/ipv4/ipmr.c index 9947f523862..772daf77878 100644 --- a/net/ipv4/ipmr.c +++ b/net/ipv4/ipmr.c @@ -749,7 +749,7 @@ static int ipmr_mfc_add(struct mfcctl *mfc, int mrtsock) return 0; } - if (!MULTICAST(mfc->mfcc_mcastgrp.s_addr)) + if (!ipv4_is_multicast(mfc->mfcc_mcastgrp.s_addr)) return -EINVAL; c=ipmr_cache_alloc(); @@ -1461,7 +1461,7 @@ int pim_rcv_v1(struct sk_buff * skb) b. packet is not a NULL-REGISTER c. packet is not truncated */ - if (!MULTICAST(encap->daddr) || + if (!ipv4_is_multicast(encap->daddr) || encap->tot_len == 0 || ntohs(encap->tot_len) + sizeof(*pim) > skb->len) goto drop; @@ -1517,7 +1517,7 @@ static int pim_rcv(struct sk_buff * skb) /* check if the inner packet is destined to mcast group */ encap = (struct iphdr *)(skb_transport_header(skb) + sizeof(struct pimreghdr)); - if (!MULTICAST(encap->daddr) || + if (!ipv4_is_multicast(encap->daddr) || encap->tot_len == 0 || ntohs(encap->tot_len) + sizeof(*pim) > skb->len) goto drop; |