summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--Bugzilla/Error.pm6
-rwxr-xr-xbugzilla.pl2
2 files changed, 6 insertions, 2 deletions
diff --git a/Bugzilla/Error.pm b/Bugzilla/Error.pm
index dcb79cfb2..d3f7c1971 100644
--- a/Bugzilla/Error.pm
+++ b/Bugzilla/Error.pm
@@ -124,7 +124,11 @@ sub _throw_error {
message => $message,
id => $server->{_bz_request_id},
version => $server->version);
- $server->response($server->error_response_header);
+ # if _bz_request_id is set, we're inside the _handle() function
+ # and we don't need to call $server->response.
+ unless ($self->{_bz_request_id}) {
+ $server->response($server->error_response_header);
+ }
}
}
diff --git a/bugzilla.pl b/bugzilla.pl
index 41a4d8e6a..efcea293b 100755
--- a/bugzilla.pl
+++ b/bugzilla.pl
@@ -1,4 +1,4 @@
-#!/usr/bin/env perl
+#!/usr/bin/perl
use 5.10.1;
use strict;
use warnings;