From a4ebe5a0284255cc7a0946f1e895af94e37b7c86 Mon Sep 17 00:00:00 2001 From: Pascal Rigaux Date: Fri, 19 Sep 2003 14:48:46 +0000 Subject: - read_gnomekderc() & update_gnomekderc() will now handle key=value where key can contain spaces --- MDK/Common/System.pm | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'MDK/Common') diff --git a/MDK/Common/System.pm b/MDK/Common/System.pm index de9e3d4..40c1fc8 100644 --- a/MDK/Common/System.pm +++ b/MDK/Common/System.pm @@ -360,7 +360,7 @@ sub read_gnomekderc { my %h; foreach (MDK::Common::File::cat_($file), "[NOCATEGORY]\n") { if (/^\s*\[\Q$category\E\]/i ... /^\[/) { - $h{$1} = $2 if /^\s*(\w*?)=(.*)/; + $h{$1} = $2 if /^\s*([^=]*?)=(.*)/; } } %h; @@ -378,7 +378,7 @@ sub update_gnomekderc { chomp $s; $s .= "\n"; $s .= "$_->[0]=$_->[1]\n" foreach values %subst; %subst = (); - } elsif (/^\s*(\w*?)=/) { + } elsif (/^\s*([^=]*?)=/) { if (my $e = delete $subst{lc($1)}) { $_ = "$1=$e->[1]\n"; } -- cgit v1.2.1