diff options
author | Jan Engelhardt <jengelh@medozas.de> | 2010-02-24 18:32:59 +0100 |
---|---|---|
committer | Patrick McHardy <kaber@trash.net> | 2010-02-24 18:32:59 +0100 |
commit | 72b2b1dd77e8feb0b7c0b26dee58f2a1e2c9828c (patch) | |
tree | 4289fef5441a1664f60a17cb473d657f77cf1112 /include/linux/netfilter_ipv4 | |
parent | 8ccb92ad41cb311e52ad1b1fe77992c7f47a3b63 (diff) | |
download | kernel_samsung_espresso10-72b2b1dd77e8feb0b7c0b26dee58f2a1e2c9828c.zip kernel_samsung_espresso10-72b2b1dd77e8feb0b7c0b26dee58f2a1e2c9828c.tar.gz kernel_samsung_espresso10-72b2b1dd77e8feb0b7c0b26dee58f2a1e2c9828c.tar.bz2 |
netfilter: xtables: replace XT_ENTRY_ITERATE macro
The macro is replaced by a list.h-like foreach loop. This makes
the code much more inspectable.
Signed-off-by: Jan Engelhardt <jengelh@medozas.de>
Signed-off-by: Patrick McHardy <kaber@trash.net>
Diffstat (limited to 'include/linux/netfilter_ipv4')
-rw-r--r-- | include/linux/netfilter_ipv4/ip_tables.h | 11 |
1 files changed, 2 insertions, 9 deletions
diff --git a/include/linux/netfilter_ipv4/ip_tables.h b/include/linux/netfilter_ipv4/ip_tables.h index 364973b..5b20ae7 100644 --- a/include/linux/netfilter_ipv4/ip_tables.h +++ b/include/linux/netfilter_ipv4/ip_tables.h @@ -227,9 +227,11 @@ ipt_get_target(struct ipt_entry *e) #define IPT_MATCH_ITERATE(e, fn, args...) \ XT_MATCH_ITERATE(struct ipt_entry, e, fn, ## args) +#ifndef __KERNEL__ /* fn returns 0 to continue iteration */ #define IPT_ENTRY_ITERATE(entries, size, fn, args...) \ XT_ENTRY_ITERATE(struct ipt_entry, entries, size, fn, ## args) +#endif /* * Main firewall chains definitions and global var's definitions. @@ -317,15 +319,6 @@ compat_ipt_get_target(struct compat_ipt_entry *e) #define COMPAT_IPT_MATCH_ITERATE(e, fn, args...) \ XT_MATCH_ITERATE(struct compat_ipt_entry, e, fn, ## args) -/* fn returns 0 to continue iteration */ -#define COMPAT_IPT_ENTRY_ITERATE(entries, size, fn, args...) \ - XT_ENTRY_ITERATE(struct compat_ipt_entry, entries, size, fn, ## args) - -/* fn returns 0 to continue iteration */ -#define COMPAT_IPT_ENTRY_ITERATE_CONTINUE(entries, size, n, fn, args...) \ - XT_ENTRY_ITERATE_CONTINUE(struct compat_ipt_entry, entries, size, n, \ - fn, ## args) - #endif /* CONFIG_COMPAT */ #endif /*__KERNEL__*/ #endif /* _IPTABLES_H */ |