From 06588c2e4ad9ced8da40bfc0e94850c1ce47975a Mon Sep 17 00:00:00 2001 From: Tom Eastep Date: Thu, 12 Apr 2012 06:53:58 -0700 Subject: [PATCH] Fix configure.pl Signed-off-by: Tom Eastep --- Shorewall-core/configure.pl | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) diff --git a/Shorewall-core/configure.pl b/Shorewall-core/configure.pl index 5bf0dbacc..b170fa95c 100755 --- a/Shorewall-core/configure.pl +++ b/Shorewall-core/configure.pl @@ -66,10 +66,11 @@ if ( defined $vendor ) { open $rcfile, '<', $rcfilename or die "Unable to open $rcfilename for input: $!"; while ( <$rcfile> ) { - next if /\s*#/; - - die "Invalid entry ($_) in $rcfile, line $." unless /\s*(\w+)=(.*)/; - + next if /^\s*#/; + s/\s*#.*//; + next if /^\s*$/; + chomp; + die "Invalid entry ($_) in $rcfilename, line $." unless /\s*(\w+)=(.*)/; $options{$1} = $2; }