aboutsummaryrefslogtreecommitdiffstats
path: root/net/ipv4/netfilter/ip_tables.c
diff options
context:
space:
mode:
authorPatrick McHardy <kaber@trash.net>2007-12-17 21:46:40 -0800
committerDavid S. Miller <davem@davemloft.net>2008-01-28 14:58:28 -0800
commit8956695131b8a7878891667469899d667eb5892b (patch)
tree1034260f3a5d1e7258cc2193734516a697c83e47 /net/ipv4/netfilter/ip_tables.c
parent[NETFILTER]: ip_tables: reformat compat code (diff)
downloadlinux-dev-8956695131b8a7878891667469899d667eb5892b.tar.xz
linux-dev-8956695131b8a7878891667469899d667eb5892b.zip
[NETFILTER]: x_tables: make xt_compat_match_from_user usable in iterator macros
Make xt_compat_match_from_user return an int to make it usable in the *tables iterator macros and kill a now unnecessary wrapper function. Signed-off-by: Patrick McHardy <kaber@trash.net> Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'net/ipv4/netfilter/ip_tables.c')
-rw-r--r--net/ipv4/netfilter/ip_tables.c13
1 files changed, 1 insertions, 12 deletions
diff --git a/net/ipv4/netfilter/ip_tables.c b/net/ipv4/netfilter/ip_tables.c
index 7d24262331a4..4586af397ef4 100644
--- a/net/ipv4/netfilter/ip_tables.c
+++ b/net/ipv4/netfilter/ip_tables.c
@@ -1654,16 +1654,6 @@ release_matches:
return ret;
}
-static inline int
-compat_copy_match_from_user(struct ipt_entry_match *m,
- void **dstptr, compat_uint_t *size,
- const char *name, const struct ipt_ip *ip,
- unsigned int hookmask)
-{
- xt_compat_match_from_user(m, dstptr, size);
- return 0;
-}
-
static int
compat_copy_entry_from_user(struct ipt_entry *e, void **dstptr,
unsigned int *size, const char *name,
@@ -1681,8 +1671,7 @@ compat_copy_entry_from_user(struct ipt_entry *e, void **dstptr,
memcpy(de, e, sizeof(struct ipt_entry));
*dstptr += sizeof(struct compat_ipt_entry);
- ret = IPT_MATCH_ITERATE(e, compat_copy_match_from_user, dstptr, size,
- name, &de->ip, de->comefrom);
+ ret = IPT_MATCH_ITERATE(e, xt_compat_match_from_user, dstptr, size);
if (ret)
return ret;
de->target_offset = e->target_offset - (origsize - *size);