diff options
author | Patrick McHardy <kaber@trash.net> | 2008-01-31 07:10:18 -0500 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2008-01-31 22:27:49 -0500 |
commit | b0a6363c2418c93f25dd30b8ffcd3fdd4ce23ad6 (patch) | |
tree | 81bf6cdd227ef619b8e8cb29674568725459a2fe /net/ipv4 | |
parent | 855304af29c042e002d902997661ec3dd507df0d (diff) |
[NETFILTER]: {ip,arp,ip6}_tables: fix sparse warnings in compat code
CHECK net/ipv4/netfilter/ip_tables.c
net/ipv4/netfilter/ip_tables.c:1453:8: warning: incorrect type in argument 3 (different signedness)
net/ipv4/netfilter/ip_tables.c:1453:8: expected int *size
net/ipv4/netfilter/ip_tables.c:1453:8: got unsigned int [usertype] *size
net/ipv4/netfilter/ip_tables.c:1458:44: warning: incorrect type in argument 3 (different signedness)
net/ipv4/netfilter/ip_tables.c:1458:44: expected int *size
net/ipv4/netfilter/ip_tables.c:1458:44: got unsigned int [usertype] *size
net/ipv4/netfilter/ip_tables.c:1603:2: warning: incorrect type in argument 2 (different signedness)
net/ipv4/netfilter/ip_tables.c:1603:2: expected unsigned int *i
net/ipv4/netfilter/ip_tables.c:1603:2: got int *<noident>
net/ipv4/netfilter/ip_tables.c:1627:8: warning: incorrect type in argument 3 (different signedness)
net/ipv4/netfilter/ip_tables.c:1627:8: expected int *size
net/ipv4/netfilter/ip_tables.c:1627:8: got unsigned int *size
net/ipv4/netfilter/ip_tables.c:1634:40: warning: incorrect type in argument 3 (different signedness)
net/ipv4/netfilter/ip_tables.c:1634:40: expected int *size
net/ipv4/netfilter/ip_tables.c:1634:40: got unsigned int *size
net/ipv4/netfilter/ip_tables.c:1653:8: warning: incorrect type in argument 5 (different signedness)
net/ipv4/netfilter/ip_tables.c:1653:8: expected unsigned int *i
net/ipv4/netfilter/ip_tables.c:1653:8: got int *<noident>
net/ipv4/netfilter/ip_tables.c:1666:2: warning: incorrect type in argument 2 (different signedness)
net/ipv4/netfilter/ip_tables.c:1666:2: expected unsigned int *i
net/ipv4/netfilter/ip_tables.c:1666:2: got int *<noident>
CHECK net/ipv4/netfilter/arp_tables.c
net/ipv4/netfilter/arp_tables.c:1285:40: warning: incorrect type in argument 3 (different signedness)
net/ipv4/netfilter/arp_tables.c:1285:40: expected int *size
net/ipv4/netfilter/arp_tables.c:1285:40: got unsigned int *size
net/ipv4/netfilter/arp_tables.c:1543:44: warning: incorrect type in argument 3 (different signedness)
net/ipv4/netfilter/arp_tables.c:1543:44: expected int *size
net/ipv4/netfilter/arp_tables.c:1543:44: got unsigned int [usertype] *size
CHECK net/ipv6/netfilter/ip6_tables.c
net/ipv6/netfilter/ip6_tables.c:1481:8: warning: incorrect type in argument 3 (different signedness)
net/ipv6/netfilter/ip6_tables.c:1481:8: expected int *size
net/ipv6/netfilter/ip6_tables.c:1481:8: got unsigned int [usertype] *size
net/ipv6/netfilter/ip6_tables.c:1486:44: warning: incorrect type in argument 3 (different signedness)
net/ipv6/netfilter/ip6_tables.c:1486:44: expected int *size
net/ipv6/netfilter/ip6_tables.c:1486:44: got unsigned int [usertype] *size
net/ipv6/netfilter/ip6_tables.c:1631:2: warning: incorrect type in argument 2 (different signedness)
net/ipv6/netfilter/ip6_tables.c:1631:2: expected unsigned int *i
net/ipv6/netfilter/ip6_tables.c:1631:2: got int *<noident>
net/ipv6/netfilter/ip6_tables.c:1655:8: warning: incorrect type in argument 3 (different signedness)
net/ipv6/netfilter/ip6_tables.c:1655:8: expected int *size
net/ipv6/netfilter/ip6_tables.c:1655:8: got unsigned int *size
net/ipv6/netfilter/ip6_tables.c:1662:40: warning: incorrect type in argument 3 (different signedness)
net/ipv6/netfilter/ip6_tables.c:1662:40: expected int *size
net/ipv6/netfilter/ip6_tables.c:1662:40: got unsigned int *size
net/ipv6/netfilter/ip6_tables.c:1680:8: warning: incorrect type in argument 5 (different signedness)
net/ipv6/netfilter/ip6_tables.c:1680:8: expected unsigned int *i
net/ipv6/netfilter/ip6_tables.c:1680:8: got int *<noident>
net/ipv6/netfilter/ip6_tables.c:1693:2: warning: incorrect type in argument 2 (different signedness)
net/ipv6/netfilter/ip6_tables.c:1693:2: expected unsigned int *i
net/ipv6/netfilter/ip6_tables.c:1693:2: got int *<noident>
Signed-off-by: Patrick McHardy <kaber@trash.net>
Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'net/ipv4')
-rw-r--r-- | net/ipv4/netfilter/ip_tables.c | 10 |
1 files changed, 6 insertions, 4 deletions
diff --git a/net/ipv4/netfilter/ip_tables.c b/net/ipv4/netfilter/ip_tables.c index 427bc9b3d342..a73afa1ba8b8 100644 --- a/net/ipv4/netfilter/ip_tables.c +++ b/net/ipv4/netfilter/ip_tables.c | |||
@@ -1429,7 +1429,7 @@ struct compat_ipt_replace { | |||
1429 | 1429 | ||
1430 | static int | 1430 | static int |
1431 | compat_copy_entry_to_user(struct ipt_entry *e, void __user **dstptr, | 1431 | compat_copy_entry_to_user(struct ipt_entry *e, void __user **dstptr, |
1432 | compat_uint_t *size, struct xt_counters *counters, | 1432 | unsigned int *size, struct xt_counters *counters, |
1433 | unsigned int *i) | 1433 | unsigned int *i) |
1434 | { | 1434 | { |
1435 | struct ipt_entry_target *t; | 1435 | struct ipt_entry_target *t; |
@@ -1476,7 +1476,7 @@ compat_find_calc_match(struct ipt_entry_match *m, | |||
1476 | const char *name, | 1476 | const char *name, |
1477 | const struct ipt_ip *ip, | 1477 | const struct ipt_ip *ip, |
1478 | unsigned int hookmask, | 1478 | unsigned int hookmask, |
1479 | int *size, int *i) | 1479 | int *size, unsigned int *i) |
1480 | { | 1480 | { |
1481 | struct xt_match *match; | 1481 | struct xt_match *match; |
1482 | 1482 | ||
@@ -1534,7 +1534,8 @@ check_compat_entry_size_and_hooks(struct compat_ipt_entry *e, | |||
1534 | struct ipt_entry_target *t; | 1534 | struct ipt_entry_target *t; |
1535 | struct xt_target *target; | 1535 | struct xt_target *target; |
1536 | unsigned int entry_offset; | 1536 | unsigned int entry_offset; |
1537 | int ret, off, h, j; | 1537 | unsigned int j; |
1538 | int ret, off, h; | ||
1538 | 1539 | ||
1539 | duprintf("check_compat_entry_size_and_hooks %p\n", e); | 1540 | duprintf("check_compat_entry_size_and_hooks %p\n", e); |
1540 | if ((unsigned long)e % __alignof__(struct compat_ipt_entry) != 0 | 1541 | if ((unsigned long)e % __alignof__(struct compat_ipt_entry) != 0 |
@@ -1647,7 +1648,8 @@ static int | |||
1647 | compat_check_entry(struct ipt_entry *e, const char *name, | 1648 | compat_check_entry(struct ipt_entry *e, const char *name, |
1648 | unsigned int *i) | 1649 | unsigned int *i) |
1649 | { | 1650 | { |
1650 | int j, ret; | 1651 | unsigned int j; |
1652 | int ret; | ||
1651 | 1653 | ||
1652 | j = 0; | 1654 | j = 0; |
1653 | ret = IPT_MATCH_ITERATE(e, check_match, name, &e->ip, | 1655 | ret = IPT_MATCH_ITERATE(e, check_match, name, &e->ip, |