diff options
author | mkanat%bugzilla.org <> | 2008-01-06 08:53:44 +0000 |
---|---|---|
committer | mkanat%bugzilla.org <> | 2008-01-06 08:53:44 +0000 |
commit | 22d395ee10f81ecc43ca07e2d0654c158723d05b (patch) | |
tree | 37dae0e9fd2eeef9d0e9c0a00d659d6b00329bb8 /Bugzilla.pm | |
parent | Bug 355847: Make the WebService able to add a comment to a bug (diff) | |
download | bugzilla-22d395ee10f81ecc43ca07e2d0654c158723d05b.tar.gz bugzilla-22d395ee10f81ecc43ca07e2d0654c158723d05b.tar.bz2 bugzilla-22d395ee10f81ecc43ca07e2d0654c158723d05b.zip |
Bug 407420: CGI::Carp fatalsToBrowser should happen as early as possible
Patch By Max Kanat-Alexander <mkanat@bugzilla.org> r=justdave, a=mkanat
Diffstat (limited to 'Bugzilla.pm')
-rw-r--r-- | Bugzilla.pm | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/Bugzilla.pm b/Bugzilla.pm index 075031482..c77c039ce 100644 --- a/Bugzilla.pm +++ b/Bugzilla.pm @@ -26,6 +26,15 @@ package Bugzilla; use strict; +# We want any compile errors to get to the browser, if possible. +BEGIN { + # This makes sure we're in a CGI. + if ($ENV{SERVER_SOFTWARE} && !$ENV{MOD_PERL}) { + require CGI::Carp; + CGI::Carp->import('fatalsToBrowser'); + } +} + use Bugzilla::Config; use Bugzilla::Constants; use Bugzilla::Auth; |