From 7a9f88c587187ece112e47d7c4d077e44a6afe8a Mon Sep 17 00:00:00 2001 From: Stig Thormodsrud Date: Wed, 24 Mar 2010 17:12:52 -0700 Subject: Fix 5203: negation in firewall rule causes deprecation message --- lib/Vyatta/Misc.pm | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/lib/Vyatta/Misc.pm b/lib/Vyatta/Misc.pm index 77c6218..d666ea9 100755 --- a/lib/Vyatta/Misc.pm +++ b/lib/Vyatta/Misc.pm @@ -395,10 +395,10 @@ sub getPortRuleString { . "up to 15 ports (port range counts as 2)" ); } if ( $num_ports > 1 ) { - $rule_str = " -m multiport --${prefix}ports ${negate}${port_str}"; + $rule_str = " -m multiport $negate --${prefix}ports ${port_str}"; } elsif ( $num_ports > 0 ) { - $rule_str = " --${prefix}port ${negate}${port_str}"; + $rule_str = " $negate --${prefix}port ${port_str}"; } return ( $rule_str, undef ); -- cgit v1.2.3