From 3960fa6e0e95cdf3947a7b501b8c94f4c4815dc7 Mon Sep 17 00:00:00 2001 From: Tom Eastep Date: Sat, 12 Mar 2016 09:05:30 -0800 Subject: [PATCH] Performance tweak to read_a_line() Signed-off-by: Tom Eastep --- Shorewall/Perl/Shorewall/Config.pm | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Shorewall/Perl/Shorewall/Config.pm b/Shorewall/Perl/Shorewall/Config.pm index 0df38027d..297adf07e 100644 --- a/Shorewall/Perl/Shorewall/Config.pm +++ b/Shorewall/Perl/Shorewall/Config.pm @@ -3450,7 +3450,7 @@ sub read_a_line($) { # # Suppress leading whitespace in certain continuation lines # - s/^\s*// if $currentline && $currentline =~ /[,:]$/ && $options & CONFIG_CONTINUATION; + s/^\s*// if $currentline && $options & CONFIG_CONTINUATION && $currentline =~ /[,:]$/; # # If this is a continued line with a trailing comment, remove comment. Note that # the result will now end in '\'.