From e0040f4011b70a391a227f4f89423058b9b97fc7 Mon Sep 17 00:00:00 2001 From: teastep Date: Fri, 10 Apr 2009 16:16:25 +0000 Subject: [PATCH] Small optimizations in expand_rule() Signed-off-by: Tom Eastep git-svn-id: https://shorewall.svn.sourceforge.net/svnroot/shorewall/trunk@9837 fbd18981-670d-0410-9b5c-8dc0c1a9a2bb --- Shorewall/Perl/Shorewall/Chains.pm | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) diff --git a/Shorewall/Perl/Shorewall/Chains.pm b/Shorewall/Perl/Shorewall/Chains.pm index 1fa1c25ab..9f6d5216a 100644 --- a/Shorewall/Perl/Shorewall/Chains.pm +++ b/Shorewall/Perl/Shorewall/Chains.pm @@ -2341,7 +2341,7 @@ sub expand_rule( $$$$$$$$$$ ) # # Trim disposition # - $disposition =~ s/\s+.*//; + $disposition =~ s/\s.*//; # # Handle Log Level # @@ -2415,9 +2415,7 @@ sub expand_rule( $$$$$$$$$$ ) # fatal_error "Bridge ports may not appear in the SOURCE column of this file" if port_to_bridge( $iiface ); - my $networks = get_interface_nets ( $iiface ); - - push_command $chainref, join( '', 'for source in ', $networks, '; do' ), 'done'; + push_command $chainref, join( '', 'for source in ', get_interface_nets( $iiface) , '; do' ), 'done'; $rule .= '-s $source '; } else {