summaryrefslogtreecommitdiffstats
path: root/config-db
diff options
context:
space:
mode:
authorOliver Tappe2008-01-12 17:31:35 +0100
committerOliver Tappe2008-01-12 17:31:35 +0100
commit43f8df5809a9644f8d9e488606072ee8edacf269 (patch)
treeab7a7f63c083e08f49e9ba8fbe71176a1acede30 /config-db
parent* fixed encoding problem with script-internal default PXE-template (diff)
downloadcore-43f8df5809a9644f8d9e488606072ee8edacf269.tar.gz
core-43f8df5809a9644f8d9e488606072ee8edacf269.tar.xz
core-43f8df5809a9644f8d9e488606072ee8edacf269.zip
* avoid possible warnings about undefined values in regex-substitution
git-svn-id: http://svn.openslx.org/svn/openslx/trunk@1470 95ad53e4-c205-0410-b2fa-d234c58c8868
Diffstat (limited to 'config-db')
-rwxr-xr-xconfig-db/slxconfig9
1 files changed, 5 insertions, 4 deletions
diff --git a/config-db/slxconfig b/config-db/slxconfig
index e8aaf2ca..f63224a9 100755
--- a/config-db/slxconfig
+++ b/config-db/slxconfig
@@ -194,14 +194,15 @@ sub parseKeyValueArgs
die _tr("unknown key '%s' specified for %s\n", $key, $table);
}
- if ($value eq '-') {
- $value = undef;
- }
-
# replace escaped newlines and tab chars by the respective real thing
$value =~ s{\\n}{\n}gms;
$value =~ s{\\t}{\t}gms;
+ # accept '-' as placeholder for undefined
+ if ($value eq '-') {
+ $value = undef;
+ }
+
$dataHash{$key} = $value;
}