You are viewing a plain text version of this content. The canonical link for it is here.
Posted to modperl@perl.apache.org by Hans de Groot <ha...@dandy.nl> on 2010/07/16 21:36:47 UTC
Re: add_config proxypass segfaults.
Hi,
Thank you for your reply.
I don't know why I never read about Apache2-Translation before but it
seems to do what I need.
But I am allready using my perl scripts and it's to late (to much
work) to change now. Maybe in the future.
When I have more time I am definetly going to experiment with it.
I did move the code to the PerlTransHandler and the
PerlMapToStorageHandler but the same effect.
I thought it had something to do with the / but now I only get
segfaults notmatter of I put slashes or not
I am sure I saw it working. I did get results before.
Anyway I an trying the PerlFixupHandler suggestion but I get this error:
failed to resolve handler `ModPerl::VHost_fixup': Bad name after
proxy_server' at /usr/lib/perl5/site_perl/ModPerl/VHost_fixup.pm line
26.\nCompilation failed in require at (eval 34) line 3.\n
So I guess I maybe missed some thing silly?
Do I need to add a proxy handler somewhere?
Below the handler code.
#file:ModPerl/VHost_fixup.pm
#-------------------------
package ModPerl::VHost_fixup;
use strict;
use Apache2::Const qw(OK DECLINED :options :override);
use Apache2::RequestRec ();
use APR::Finfo ();
use APR::Const -compile => qw(FINFO_NORM);
sub handler {
my $r = shift;
$r->proxyreq(2);
$r->filename('proxy:http://www.nu.nl/);
$r->handler('proxy_server');
return DECLINED;
}
1;
<http://search.cpan.org/%7Eopi/Apache2-Translation-0.32/>
Hans de Groot d
Email: hansg@dandy.nl www: http://www.dandy.nl
Re: add_config proxypass segfaults.
Posted by Hans de Groot <ha...@dandy.nl>.
Okay sorry my fault.
I missed a quote. in the line
$r->filename('proxy:http://www.nu.nl/);
Now it works perfectly.
Thank you very much for the golden tip. :-)