aboutsummaryrefslogtreecommitdiffstats
path: root/net/ipv4/igmp.c
diff options
context:
space:
mode:
authorStephen Hemminger <shemminger@linux-foundation.org>2007-10-09 04:59:42 -0400
committerDavid S. Miller <davem@sunset.davemloft.net>2007-10-10 19:54:48 -0400
commitcfcabdcc2d5a810208e5bb3974121b7ed60119aa (patch)
tree1aed711eeecc5a303b57f1fc47e1b5746e8a72c2 /net/ipv4/igmp.c
parentde83c058af25aa97ed4864abab11e90e8dead6e2 (diff)
[NET]: sparse warning fixes
Fix a bunch of sparse warnings. Mostly about 0 used as NULL pointer, and shadowed variable declarations. One notable case was that hash size should have been unsigned. Signed-off-by: Stephen Hemminger <shemminger@linux-foundation.org> Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'net/ipv4/igmp.c')
-rw-r--r--net/ipv4/igmp.c5
1 files changed, 2 insertions, 3 deletions
diff --git a/net/ipv4/igmp.c b/net/ipv4/igmp.c
index ad500a43b359..2b6e59c4c0d0 100644
--- a/net/ipv4/igmp.c
+++ b/net/ipv4/igmp.c
@@ -1695,8 +1695,8 @@ static int ip_mc_add_src(struct in_device *in_dev, __be32 *pmca, int sfmode,
1695 (void) ip_mc_del1_src(pmc, sfmode, &psfsrc[i]); 1695 (void) ip_mc_del1_src(pmc, sfmode, &psfsrc[i]);
1696 } else if (isexclude != (pmc->sfcount[MCAST_EXCLUDE] != 0)) { 1696 } else if (isexclude != (pmc->sfcount[MCAST_EXCLUDE] != 0)) {
1697#ifdef CONFIG_IP_MULTICAST 1697#ifdef CONFIG_IP_MULTICAST
1698 struct in_device *in_dev = pmc->interface;
1699 struct ip_sf_list *psf; 1698 struct ip_sf_list *psf;
1699 in_dev = pmc->interface;
1700#endif 1700#endif
1701 1701
1702 /* filter mode change */ 1702 /* filter mode change */
@@ -1799,7 +1799,7 @@ static int ip_mc_leave_src(struct sock *sk, struct ip_mc_socklist *iml,
1799{ 1799{
1800 int err; 1800 int err;
1801 1801
1802 if (iml->sflist == 0) { 1802 if (iml->sflist == NULL) {
1803 /* any-source empty exclude case */ 1803 /* any-source empty exclude case */
1804 return ip_mc_del_src(in_dev, &iml->multi.imr_multiaddr.s_addr, 1804 return ip_mc_del_src(in_dev, &iml->multi.imr_multiaddr.s_addr,
1805 iml->sfmode, 0, NULL, 0); 1805 iml->sfmode, 0, NULL, 0);
@@ -2167,7 +2167,6 @@ int ip_mc_gsfget(struct sock *sk, struct group_filter *gsf,
2167 return -EFAULT; 2167 return -EFAULT;
2168 } 2168 }
2169 for (i=0; i<copycount; i++) { 2169 for (i=0; i<copycount; i++) {
2170 struct sockaddr_in *psin;
2171 struct sockaddr_storage ss; 2170 struct sockaddr_storage ss;
2172 2171
2173 psin = (struct sockaddr_in *)&ss; 2172 psin = (struct sockaddr_in *)&ss;