summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authortetragon <tetragon@4979c152-3d1c-0410-bac9-87ea11338e46>2007-10-18 02:35:07 +0000
committertetragon <tetragon@4979c152-3d1c-0410-bac9-87ea11338e46>2007-10-18 02:35:07 +0000
commita0fbd781d3cd716891365919a189a3288ad0ebc9 (patch)
tree27b1b1cfc48e518cdd308680495f890c986946db
parentd690599facd60903dbac6def6b2fe8930f9df932 (diff)
Fixing 1814437
git-svn-id: https://ledger-smb.svn.sourceforge.net/svnroot/ledger-smb/branches/1.2@1784 4979c152-3d1c-0410-bac9-87ea11338e46
-rw-r--r--LedgerSMB/Sysconfig.pm14
1 files changed, 10 insertions, 4 deletions
diff --git a/LedgerSMB/Sysconfig.pm b/LedgerSMB/Sysconfig.pm
index 6474dfd6..8d4c281b 100644
--- a/LedgerSMB/Sysconfig.pm
+++ b/LedgerSMB/Sysconfig.pm
@@ -87,10 +87,16 @@ $language = $config{''}{language} if $config{''}{language};
$session = $config{''}{session} if $config{''}{session};
$latex = $config{''}{latex} if $config{''}{latex};
-$ENV{PATH} .= $pathsep . ( join $pathsep, @{ $config{environment}{PATH} } )
- if $config{environment}{PATH};
-$ENV{PERL5LIB} .= ":" . ( join ':', @{ $config{environment}{PERL5LIB} } )
- if $config{environment}{PERL5LIB};
+if (ref $config{environment}{PATH} eq 'ARRAY') {
+ $ENV{PATH} .= $pathsep . ( join $pathsep, @{ $config{environment}{PATH} } );
+} elsif ($config{environment}{PATH}) {
+ $ENV{PATH} .= $pathsep . $config{environment}{PATH};
+}
+if (ref $config{environment}{PERL5LIB} eq 'ARRAY') {
+ $ENV{PERL5LIB} .= ":" . ( join ':', @{ $config{environment}{PERL5LIB} } );
+} elsif ($config{environment}{PERL5LIB}) {
+ $ENV{PERL5LIB} .= ":" . $config{environment}{PERL5LIB};
+}
%printer = %{ $config{printers} } if $config{printers};