From: lpsolit%gmail.com <> Date: Fri, 5 Jan 2007 08:03:58 +0000 (+0000) Subject: Bug 365035: sendmail cannot execute importxml.pl from any other path than the bugzill... X-Git-Tag: bugzilla-2.22.2~7 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=fcbde9593df17b8074718ee862b357b7609129e3;p=thirdparty%2Fbugzilla.git Bug 365035: sendmail cannot execute importxml.pl from any other path than the bugzilla directory - Patch by Guzmán Brasó r=ghendricks a=myk --- diff --git a/Bugzilla/Config.pm b/Bugzilla/Config.pm index 6df6440143..db7cb28b27 100644 --- a/Bugzilla/Config.pm +++ b/Bugzilla/Config.pm @@ -27,6 +27,7 @@ # Christopher Aillon # Erik Stambaugh # Frédéric Buclin +# Guzman Braso package Bugzilla::Config; @@ -53,6 +54,14 @@ use base qw(Exporter); # constant paths our $libpath = '.'; + +# importxml.pl, when run by a mail daemon, sets the bugzilla path explicitly. +# This then mucks it up, so if we are coming from importxml.pl, set $libpath +# back to the way it was. +if ($::path) { + $libpath = $::path; +} + our $templatedir = "$libpath/template"; # variable paths