From 851775e19381df0df846591a04852f569e59c838 Mon Sep 17 00:00:00 2001 From: Bar Ziony Date: Fri, 20 Jan 2012 00:31:19 +0200 Subject: [PATCH] Fixed bug with config reading - valid values with '#' get truncated. --- mogstats | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/mogstats b/mogstats index 2566fc8..e2c5d52 100755 --- a/mogstats +++ b/mogstats @@ -159,7 +159,7 @@ foreach my $fn (reverse @configs) { open FILE, "<$fn" or die "unable to open $fn: $!\n"; while () { - s/\#.*//; + s/\s+#.*//; next unless m/^\s*(\w+)\s*=\s*(.+?)\s*$/; $opts{$1} = $2 unless ( defined $opts{$1} ); }