summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorPhil Sutter <phil@nwl.cc>2020-05-06 12:27:49 +0200
committerPhil Sutter <phil@nwl.cc>2020-05-11 14:28:29 +0200
commitb3b7eb6ce8773bcc76f603ebb0e606001894da34 (patch)
treeb5aae23f632924c509de5ed64478837ccb3f0570
parent381b5569eb256e13346cff902d6ceed42cb441ad (diff)
arptables: Fix leak in nft_arp_print_rule()
The function missed to clear struct iptables_command_state again after use. Signed-off-by: Phil Sutter <phil@nwl.cc>
-rw-r--r--iptables/nft-arp.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/iptables/nft-arp.c b/iptables/nft-arp.c
index e9a2d9de..9a831efd 100644
--- a/iptables/nft-arp.c
+++ b/iptables/nft-arp.c
@@ -604,6 +604,8 @@ nft_arp_print_rule(struct nft_handle *h, struct nftnl_rule *r,
if (!(format & FMT_NONEWLINE))
fputc('\n', stdout);
+
+ nft_clear_iptables_command_state(&cs);
}
static bool nft_arp_is_same(const void *data_a,