From 45dab0a69a6d22dd13aa625970c4b673afea535c Mon Sep 17 00:00:00 2001 From: pcanterino <> Date: Thu, 28 Oct 2004 09:45:07 +0000 Subject: [PATCH 1/1] Removing one and more whitespace makes more sense than removing no, one and more whitespaces. --- modules/Config/DevEdit.pm | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/modules/Config/DevEdit.pm b/modules/Config/DevEdit.pm index e423819..24b3fe1 100644 --- a/modules/Config/DevEdit.pm +++ b/modules/Config/DevEdit.pm @@ -6,7 +6,7 @@ package Config::DevEdit; # Read and parse the configuration files # # Author: Patrick Canterino -# Last modified: 2004-04-25 +# Last modified: 2004-10-28 # use strict; @@ -42,7 +42,7 @@ sub read_config($) # parse_config() # -# Parse an INI-style configuration file +# Parse a configuration file # # Params: Path to configuration file # @@ -69,10 +69,10 @@ sub parse_config($) # Remove whitespaces at the beginning and at the end - $key =~ s/^\s*//g; - $key =~ s/\s*$//g; - $value =~ s/^\s*//g; - $value =~ s/\s*$//g; + $key =~ s/^\s+//g; + $key =~ s/\s+$//g; + $value =~ s/^\s+//g; + $value =~ s/\s+$//g; croak "Double defined value '$key' in configuration file '$file'" if($config->{$key}); -- 2.34.1