diff options
author | Phil Sutter <phil@nwl.cc> | 2019-10-22 20:06:11 +0200 |
---|---|---|
committer | Phil Sutter <phil@nwl.cc> | 2021-11-23 15:01:23 +0100 |
commit | a323c28331a4807252b11a7a078dc68af82399ef (patch) | |
tree | 2ff3f5d9f69c5897adb4bb515c452497b0f75f54 /iptables/nft-ipv6.c | |
parent | 1d73cec02c8d9a0f5bfbd2983c36cc1228b78f45 (diff) |
xshared: Share print_fragment() with legacy
Also add a fake mode to make it suitable for ip6tables. This is required
because IPT_F_FRAG value clashes with IP6T_F_PROTO, so ip6tables rules
might seem to have IPT_F_FRAG bit set.
While being at it, drop the local variable 'flags' from
print_firewall().
Signed-off-by: Phil Sutter <phil@nwl.cc>
Diffstat (limited to 'iptables/nft-ipv6.c')
-rw-r--r-- | iptables/nft-ipv6.c | 6 |
1 files changed, 1 insertions, 5 deletions
diff --git a/iptables/nft-ipv6.c b/iptables/nft-ipv6.c index cb83f9e1..13213088 100644 --- a/iptables/nft-ipv6.c +++ b/iptables/nft-ipv6.c @@ -200,11 +200,7 @@ static void nft_ipv6_print_rule(struct nft_handle *h, struct nftnl_rule *r, print_rule_details(num, &cs.counters, cs.jumpto, cs.fw6.ipv6.proto, cs.fw6.ipv6.flags, cs.fw6.ipv6.invflags, format); - if (format & FMT_OPTIONS) { - if (format & FMT_NOTABLE) - fputs("opt ", stdout); - fputs(" ", stdout); - } + print_fragment(cs.fw6.ipv6.flags, cs.fw6.ipv6.invflags, format, true); print_ifaces(cs.fw6.ipv6.iniface, cs.fw6.ipv6.outiface, cs.fw6.ipv6.invflags, format); print_ipv6_addresses(&cs.fw6, format); |