From 6efdd49e257759fd68ac0c4689e5b67994f7c330 Mon Sep 17 00:00:00 2001 From: Byron Jones Date: Fri, 2 Mar 2012 15:20:12 +0800 Subject: Bug 732023: fix perl syntax errors causing infinite loop --- Bugzilla/Arecibo.pm | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'Bugzilla/Arecibo.pm') diff --git a/Bugzilla/Arecibo.pm b/Bugzilla/Arecibo.pm index 9e64d3889..54458cca2 100644 --- a/Bugzilla/Arecibo.pm +++ b/Bugzilla/Arecibo.pm @@ -222,6 +222,7 @@ sub _in_eval { my $in_eval = 0; for (my $stack = 1; my $sub = (caller($stack))[3]; $stack++) { last if $sub =~ /^ModPerl/; + last if $sub =~ /^Bugzilla::Template/; $in_eval = 1 if $sub =~ /^\(eval\)/; } return $in_eval; @@ -232,7 +233,7 @@ BEGIN { CGI::Carp::set_die_handler(sub { return if _in_eval(); my $message = shift; - my $is_compilation_failure = $message =~ /\bcompilation aborted\b/; + my $is_compilation_failure = $message =~ /\bcompilation (aborted|failed)\b/i; if (!$is_compilation_failure) { eval { Bugzilla::Error::ThrowTemplateError($message) }; } -- cgit v1.2.3-24-g4f1b