You are viewing a plain text version of this content. The canonical link for it is here.
Posted to modperl@perl.apache.org by Kevin Field <ke...@gmail.com> on 2010/11/11 19:17:02 UTC

Apache2::Request::param returns () despite parameters in URI, but only under Strawberry Perl

Hi everyone,

(This is a cross-post from StackOverflow.  I thought there might be more
specialized experience on this list to beg help from.  :) )

I'm running mod_perl 2.0.4 on Perl 5.10 on Apache 2.2.17 on Win2k3sp2.

The URI I am typing into my browser is http://myserver/?login=0.

The script being run is:

###


use strict;
use warnings FATAL => 'all';
use 5.01;

my $r = shift;
use Apache2::Request;
my $req = Apache2::Request->new($r);

use Data::Dump qq(pp);
die pp($req->unparsed_uri) . ', ' . pp($req->param) . ', ' .
pp($req->args_status());


###

Under Strawberry Perl, I get:

  "/?login=0", (), "No error" at C:/myweb/index.pl line 10.

...but under ActiveState Perl (see below), I get:

  "/?login=0", "login", "No error" at C:/myweb/index.pl line 10.

So I know my login parameter is making it in at some point under Strawberry,
because the unparsed URI contains it. Why is it then not being parsed
correctly?

The way I switch between the two is to simply change httpd.conf from saying

LoadFile "C:\strawberry\perl\bin\perl510.dll"
# Apache/2.2.17 (Win32) mod_apreq2-20090110/2.7.1 mod_perl/2.0.4
Perl/v5.10.1

...to this:

LoadFile "C:\Perl\bin\perl510.dll"
# Apache/2.2.17 (Win32) mod_apreq2-20051231/2.6.2-dev mod_perl/2.0.4-dev
Perl/v5.10.1

...and then restart. No other changes, it's repeatable every time switching
between the two.

Any ideas?  I'd really like to try switching to Strawberry if possible,
mostly because ActivePerl's DBD::Pg builds are getting stale, and the latest
upgrade to Apache 2.2.17 has been causing random/intermittent Apache service
crashes for us these past couple weeks, I think related to DBD::Pg.

Thanks in advance for any help,
Kev

Re: Apache2::Request::param returns () despite parameters in URI, but only under Strawberry Perl

Posted by Kevin Field <ke...@gmail.com>.
>
> > This is a cross-post from StackOverflow.
>
> URL?
>

Sorry:
http://stackoverflow.com/questions/4140868/apache2requestparam-returns-despite-parameters-in-uri-but-only-under-stra


> A bug in the Apache2::Request/mod_apreq2 version shipping with
> Strawberry? Seems unlikely, though.
>

This is what I wondered, but the kind of thing that's beyond my ability to
dig into...


> > because ActivePerl's DBD::Pg builds are getting stale, and the latest
> > upgrade to Apache 2.2.17 has been causing random/intermittent Apache
> > service crashes for us these past couple weeks, I think related to
> > DBD::Pg.
>
> Try reporting it on the ActivePerl mailing list.
>

Will do.  Thanks, Michael.

Kev

Re: Apache2::Request::param returns () despite parameters in URI, but only under Strawberry Perl

Posted by Michael Ludwig <mi...@gmx.de>.
Kevin Field schrieb am 11.11.2010 um 13:17 (-0500):

> This is a cross-post from StackOverflow.

URL?

> Under Strawberry Perl, I get:
> 
>   "/?login=0", (), "No error" at C:/myweb/index.pl line 10.
> 
> ...but under ActiveState Perl (see below), I get:
> 
>   "/?login=0", "login", "No error" at C:/myweb/index.pl line 10.
> 
> So I know my login parameter is making it in at some point under
> Strawberry, because the unparsed URI contains it. Why is it then not
> being parsed correctly?

A bug in the Apache2::Request/mod_apreq2 version shipping with
Strawberry? Seems unlikely, though.

> LoadFile "C:\strawberry\perl\bin\perl510.dll"
> # Apache/2.2.17 (Win32) mod_apreq2-20090110/2.7.1 mod_perl/2.0.4
> Perl/v5.10.1

> LoadFile "C:\Perl\bin\perl510.dll"
> # Apache/2.2.17 (Win32) mod_apreq2-20051231/2.6.2-dev
> mod_perl/2.0.4-dev Perl/v5.10.1

> I'd really like to try switching to Strawberry if possible, mostly
> because ActivePerl's DBD::Pg builds are getting stale, and the latest
> upgrade to Apache 2.2.17 has been causing random/intermittent Apache
> service crashes for us these past couple weeks, I think related to
> DBD::Pg.

Try reporting it on the ActivePerl mailing list.

-- 
Michael Ludwig