You are viewing a plain text version of this content. The canonical link for it is here.
Posted to modperl@perl.apache.org by jonathan vanasco <jv...@mastersofbranding.com> on 2005/02/20 02:37:17 UTC
Trouble Setting POST_MAX
preface -- sorry if this is a double post, i accidentally sent from
another address earlier, and i believe this list doesn't post
non-subscriber messages.
Admittedly, this is due to user error and incompetence
mod_perl2 / apache2 / libaprq is the latest
This works:
sub handler
{
my $r = shift;
};
Based on the examples in the book/cookbook and online, I thought I was
supposed to do this:
sub handler
{
my $r = Apache::Request->new(shift,
POST_MAX => .1 * 1024 * 1024, # in bytes, so 100K
DISABLE_UPLOADS => 0
);
}
That turns into a segfault.
can someone point out my mistake?
Re: Trouble Setting POST_MAX
Posted by Joe Schaefer <jo...@sunstarsys.com>.
Jonathan Vanasco <jv...@mastersofbranding.com> writes:
> On Feb 21, 2005, at 10:45 PM, Ian Joyce wrote:
>> Shouldn't you be using Apache::RequestRec?
>
> Should I?
No, it doesn't parse form data.
> All the docs show Apache::Request for this sort of thing, and
> Apache::Request has the $r->param('fieldname') manner of reading
> GET/POST fields
The bug looks familiar to me, so you might try testing
apreq's subversion trunk to see if we have already fixed
it there. Otherwise try dropping the DISABLE_UPLOADS => 0
argument and see if the segfaults persist.
--
Joe Schaefer
Re: Trouble Setting POST_MAX
Posted by Jonathan Vanasco <jv...@mastersofbranding.com>.
On Feb 21, 2005, at 10:45 PM, Ian Joyce wrote:
> Shouldn't you be using Apache::RequestRec?
Should I?
All the docs show Apache::Request for this sort of thing, and
Apache::Request has the $r->param('fieldname') manner of reading
GET/POST fields
I'm oblivious to 99.1% of mod_perl though, so if i'm wrong on this,
please straighten me out.
Re: Trouble Setting POST_MAX
Posted by Ian Joyce <ia...@gmail.com>.
On Sat, 19 Feb 2005 20:37:17 -0500, jonathan vanasco
<jv...@mastersofbranding.com> wrote:
> {
> my $r = Apache::Request->new(shift,
> POST_MAX => .1 * 1024 * 1024, # in bytes, so 100K
> DISABLE_UPLOADS => 0
> );
> }
Shouldn't you be using Apache::RequestRec?
--Ian
RE: Trouble Setting POST_MAX
Posted by pileswasp <pi...@hotmail.com>.
>From: jonathan vanasco <jv...@mastersofbranding.com>
>Date: Sat, 19 Feb 2005 20:37:17 -0500
>
>[...]
>
>sub handler
>{
> my $r = Apache::Request->new(shift,
> POST_MAX => .1 * 1024 * 1024, # in bytes, so 100K
> DISABLE_UPLOADS => 0
> );
>}
>
>That turns into a segfault.
.1 * 1024 * 1024 = 104857.6
Perhaps .6 of a byte is difficult for it to cope with?