From 44599183868f111d80e34b07fa69b66775df6aff Mon Sep 17 00:00:00 2001 From: Paolo Valerio Date: Mon, 7 Oct 2024 17:54:25 +0200 Subject: [PATCH] ovs-macros.at: Correctly delete iptables rule on_exit. Currently, at every call of IPTABLES_ACCEPT() an iptables rule gets added. Such rule is supposed to be removed on exit, but the current syntax for deleting the rule is incorrect, resulting in a leftover rule after execution. Fix it by correcting the deletion command. Fixes: 5e06e7ac99dc ("tests: Refactor the iptables accept rule.") Reviewed-by: Aaron Conole Acked-by: Simon Horman Acked-by: Eelco Chaudron Signed-off-by: Paolo Valerio Signed-off-by: Aaron Conole --- tests/ovs-macros.at | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/tests/ovs-macros.at b/tests/ovs-macros.at index 06c978555..f1b8041fb 100644 --- a/tests/ovs-macros.at +++ b/tests/ovs-macros.at @@ -365,4 +365,4 @@ dnl to reject input traffic from bridges such as br-underlay. dnl Add a rule to always accept the traffic. m4_define([IPTABLES_ACCEPT], [AT_CHECK([iptables -I INPUT 1 -i $1 -j ACCEPT]) - on_exit 'iptables -D INPUT 1 -i $1']) + on_exit 'iptables -D INPUT 1'])