perl-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Josh Chamas <j...@chamas.com>
Subject [mp2] $r->current_callback please
Date Wed, 07 May 2003 20:44:57 GMT
Hey,

I was wondering if we could get $r->current_callback into the standard mp2 API.
It will just be one less thing to worry about when making things work across
mp2 & mp1.

Currently, this is implemented in Apache::compat with a call to
Apache::current_callback, but I was wondering if this could be made
standard for $r, maybe in addition to Apache::current_callback() working ...

I have code in Apache::ASP that I am working on that is looking like:

	my $current_callback = eval { $r->current_callback } || eval { Apache::current_callback()
};
	if($current_callback) {
	    $request_binary_read = ($current_callback =~ /^Perl(Response)?Handler$/) ? 1 : 0;
	} else {
	    $request_binary_read = 1;
	}																																																																	
Like other environments I am sure, Apache::ASP runs in at least 3 modes,
which is why this coding gets hairy... so far its running in mp1, mp2, & mod_cgi.
I have a CGI $r emulator, but it ends up looking more like mp1 than mp2.

Regards,

Josh																																																																	

________________________________________________________________
Josh Chamas, Founder                   phone:925-552-0128
Chamas Enterprises Inc.                http://www.chamas.com
NodeWorks Link Checking                http://www.nodeworks.com



---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@perl.apache.org
For additional commands, e-mail: dev-help@perl.apache.org


Mime
View raw message