On Wed, 1 Nov 2000, Paul J. Lucas wrote:
If I'm a few levels deep into function calls, I'd liek to be
able to do something like "return SERVER_ERROR" and have the
entire call stack unwind and the current request stopped.
Is there any way to do that?
Not that this
On Wed, 1 Nov 2000 11:37:00 -0800 (PST), "Paul J. Lucas" wrote:
If I'm a few levels deep into function calls, I'd liek to be
able to do something like "return SERVER_ERROR" and have the
entire call stack unwind and the current request stopped.
Will something like this do
Hi there,
On Wed, 1 Nov 2000, Paul J. Lucas wrote:
If I'm a few levels deep into function calls, I'd liek to be
able to do something like "return SERVER_ERROR" and have the
entire call stack unwind and the current request stopped.
Is there any way to do that?
It's
On Wed, 1 Nov 2000, G.W. Haywood wrote:
Or you could call a function which does the business and then calls
mod_perl's exit() function, page 464 Eagle Book.
I tried exit: the status code isn't preserved to downstream
stacked handlers.
- Paul
On Wed, 1 Nov 2000, Dave Rolsky wrote:
On Wed, 1 Nov 2000, Paul J. Lucas wrote:
If I'm a few levels deep into function calls, I'd liek to be
able to do something like "return SERVER_ERROR" and have the
entire call stack unwind and the current request stopped.
Is
On Wed, 1 Nov 2000, Paul J. Lucas wrote:
If I'm a few levels deep into function calls, I'd liek to be
able to do something like "return SERVER_ERROR" and have the
entire call stack unwind and the current request stopped.
Is there any way to do that?
Definitely use
On Wed, 1 Nov 2000, Matt Sergeant wrote:
Definitely use exceptions. I prefer Error.pm for this (sorry, Dave!),
which allows your handler to simply be:
That's no reason not to use Exception::Class. They are largely
orthogonal. If you want to be able to declare your exception hierarchy at
On Wed, 1 Nov 2000, Matt Sergeant wrote:
On Wed, 1 Nov 2000, Paul J. Lucas wrote:
If I'm a few levels deep into function calls, I'd liek to be
able to do something like "return SERVER_ERROR" and have the
entire call stack unwind and the current request stopped.
Is
On Wed, 1 Nov 2000, Matt Sergeant wrote:
Definitely use exceptions. I prefer Error.pm for this (sorry, Dave!),
which allows your handler to simply be:
sub handler {
return try {
...
} catch Exception::RetCode with {
my $E = shift;
On Wed, 1 Nov 2000, Paul J. Lucas wrote:
Ideally, I want to be able to do:
sub foo {
if ( $serious_problem )
stop_now_dammit( SERVER_ERROR );
}
anywhere in the code like:
sub
even better: Apache-exit(SERVER_ERROR);. or die SERVER_ERROR;. this is
documented in the eagle book:
ch9 - The Apache::Constants Class
"...
While the HTTP constants are generally used as return codes from
handler subroutines, it is also possible to use the builtin die()
function to jump out
On Wed, 1 Nov 2000, Paul J. Lucas wrote:
On Wed, 1 Nov 2000, John K. Sterling wrote:
even better: Apache-exit(SERVER_ERROR);
The documentation for exit() deosnt' explicitly say you can do
that. It mentions only "0" and "DONE" (see pp. 464-465).
it works though,
On Wed, 1 Nov 2000, Dave Rolsky wrote:
On Wed, 1 Nov 2000, Paul J. Lucas wrote:
If I'm a few levels deep into function calls, I'd liek to be
able to do something like "return SERVER_ERROR" and have the
entire call stack unwind and the current request stopped.
Is
13 matches
Mail list logo