summaryrefslogtreecommitdiffstats
path: root/iptables/xshared.h
diff options
context:
space:
mode:
authorPhil Sutter <phil@nwl.cc>2021-10-21 13:04:45 +0200
committerPhil Sutter <phil@nwl.cc>2021-12-16 14:30:29 +0100
commit56ac0452a4968f1af8d3ad1717c8646593177155 (patch)
tree6ad235caf1c5ccf8fa24f3b737b2cf3ae1aaafbd /iptables/xshared.h
parent4149b5d836340c744c78f303e2a877a89c271000 (diff)
xshared: Share a common printhelp function
Help texts in legacy and nft variants are supposed to be identical, but those of iptables and ip6tables largely overlapped already. By referring to xt_params and afinfo pointers, it is relatively trivial to craft a suitable help text on demand, so duplicated help texts can be eliminated. As a side-effect, this fixes ip6tables-nft help text - it was identical to that of iptables-nft. Signed-off-by: Phil Sutter <phil@nwl.cc>
Diffstat (limited to 'iptables/xshared.h')
-rw-r--r--iptables/xshared.h2
1 files changed, 2 insertions, 0 deletions
diff --git a/iptables/xshared.h b/iptables/xshared.h
index 1ee64d9e..3310954c 100644
--- a/iptables/xshared.h
+++ b/iptables/xshared.h
@@ -259,4 +259,6 @@ void save_rule_details(const char *iniface, unsigned const char *iniface_mask,
int print_match_save(const struct xt_entry_match *e, const void *ip);
+void xtables_printhelp(const struct xtables_rule_match *matches);
+
#endif /* IPTABLES_XSHARED_H */