Skip Menu |

This queue is for tickets about the clearpress CPAN distribution.

Report information
The Basics
Id: 48383
Status: resolved
Priority: 0/
Queue: clearpress

People
Owner: Nobody in particular
Requestors: SREZIC [...] cpan.org
Cc:
AdminCc:

Bug Information
Severity: (no value)
Broken in: 338
Fixed in: (no value)



Subject: t/30-controller-requests.t hangs, waiting for STDIN
The t/30-controller-requests.t test hangs on my system (FreeBSD 7.0, perl 5.8.8). Attached is the log created with perl -d:Trace. It seems like at this point CGI is trying to read POST (?) content from STDIN. Regards, Slaven
Subject: clearpress-trace.log
>> t/request.pm:22: $ENV{SERVER_PROTOCOL} = q[HTTP]; >> t/request.pm:23: $ENV{REQUEST_METHOD} = $ref->{REQUEST_METHOD}; >> t/request.pm:24: $ENV{PATH_INFO} = $ref->{PATH_INFO}; >> t/request.pm:25: $ENV{REQUEST_URI} = "/clearpress-test$ref->{PATH_INFO}"; >> t/request.pm:27: my $util = $ref->{util} || t::util->new({ >> t/request.pm:30: $util->cgi(CGI->new()); >> /usr/perl5.8.8@RELEASE/lib/5.8.8/CGI.pm:331: my($class,@initializer) = @_; >> /usr/perl5.8.8@RELEASE/lib/5.8.8/CGI.pm:332: my $self = {}; >> /usr/perl5.8.8@RELEASE/lib/5.8.8/CGI.pm:334: bless $self,ref $class || $class || $DefaultClass; >> /usr/perl5.8.8@RELEASE/lib/5.8.8/CGI.pm:337: $self->{'use_tempfile'} = 1; >> /usr/perl5.8.8@RELEASE/lib/5.8.8/CGI.pm:339: if (ref($initializer[0]) >> /usr/perl5.8.8@RELEASE/lib/5.8.8/CGI.pm:346: if (ref($initializer[0]) >> /usr/perl5.8.8@RELEASE/lib/5.8.8/CGI.pm:351: if ($MOD_PERL) { >> /usr/perl5.8.8@RELEASE/lib/5.8.8/CGI.pm:369: $self->_reset_globals if $PERLEX; >> /usr/perl5.8.8@RELEASE/lib/5.8.8/CGI.pm:370: $self->init(@initializer); >> /usr/perl5.8.8@RELEASE/lib/5.8.8/CGI.pm:497: my $self = shift; >> /usr/perl5.8.8@RELEASE/lib/5.8.8/CGI.pm:498: my($query_string,$meth,$content_length,$fh,@lines) = ('','','',''); >> /usr/perl5.8.8@RELEASE/lib/5.8.8/CGI.pm:500: my $is_xforms; >> /usr/perl5.8.8@RELEASE/lib/5.8.8/CGI.pm:502: my $initializer = shift; # for backward compatibility >> /usr/perl5.8.8@RELEASE/lib/5.8.8/CGI.pm:503: local($/) = "\n"; >> /usr/perl5.8.8@RELEASE/lib/5.8.8/CGI.pm:506: $self->{'escape'} = 1; >> /usr/perl5.8.8@RELEASE/lib/5.8.8/CGI.pm:511: if (defined(@QUERY_PARAM) && !defined($initializer)) { >> /usr/perl5.8.8@RELEASE/lib/5.8.8/CGI.pm:528: $meth=$ENV{'REQUEST_METHOD'} if defined($ENV{'REQUEST_METHOD'}); >> /usr/perl5.8.8@RELEASE/lib/5.8.8/CGI.pm:529: $content_length = defined($ENV{'CONTENT_LENGTH'}) ? $ENV{'CONTENT_LENGTH'} : 0; >> /usr/perl5.8.8@RELEASE/lib/5.8.8/CGI.pm:531: $fh = to_filehandle($initializer) if $initializer; >> /usr/perl5.8.8@RELEASE/lib/5.8.8/CGI.pm:534: $self->charset('ISO-8859-1'); >> /usr/perl5.8.8@RELEASE/lib/5.8.8/CGI.pm:951: my ($self,$charset) = self_or_default(@_); >> /usr/perl5.8.8@RELEASE/lib/5.8.8/CGI.pm:462: return @_ if defined($_[0]) && (!ref($_[0])) &&($_[0] eq 'CGI'); >> /usr/perl5.8.8@RELEASE/lib/5.8.8/CGI.pm:463: unless (defined($_[0]) && >> /usr/perl5.8.8@RELEASE/lib/5.8.8/CGI.pm:469: return wantarray ? @_ : $Q; >> /usr/perl5.8.8@RELEASE/lib/5.8.8/CGI.pm:952: $self->{'.charset'} = $charset if defined $charset; >> /usr/perl5.8.8@RELEASE/lib/5.8.8/CGI.pm:953: $self->{'.charset'}; >> /usr/perl5.8.8@RELEASE/lib/5.8.8/CGI.pm:539: if (($POST_MAX > 0) && ($content_length > $POST_MAX)) { >> /usr/perl5.8.8@RELEASE/lib/5.8.8/CGI.pm:539: if (($POST_MAX > 0) && ($content_length > $POST_MAX)) { >> /usr/perl5.8.8@RELEASE/lib/5.8.8/CGI.pm:547: if ($meth eq 'POST' >> /usr/perl5.8.8@RELEASE/lib/5.8.8/CGI.pm:572: if ($meth eq 'POST' && defined($ENV{'CONTENT_TYPE'})) { >> /usr/perl5.8.8@RELEASE/lib/5.8.8/CGI.pm:600: if (!$is_xforms && defined($initializer)) { >> /usr/perl5.8.8@RELEASE/lib/5.8.8/CGI.pm:636: if ($is_xforms || $meth=~/^(GET|HEAD)$/) { >> /usr/perl5.8.8@RELEASE/lib/5.8.8/CGI.pm:646: if ($meth eq 'POST' || $meth eq 'PUT') { >> /usr/perl5.8.8@RELEASE/lib/5.8.8/CGI.pm:647: if ( $content_length > 0 ) { >> /usr/perl5.8.8@RELEASE/lib/5.8.8/CGI.pm:651: $self->read_from_stdin(\$query_string); >> /usr/perl5.8.8@RELEASE/lib/5.8.8/CGI.pm:840: print STDERR "CGI::AUTOLOAD for $AUTOLOAD\n" if $CGI::AUTOLOAD_DEBUG; >> /usr/perl5.8.8@RELEASE/lib/5.8.8/CGI.pm:841: my $func = &_compile; >> /usr/perl5.8.8@RELEASE/lib/5.8.8/CGI.pm:846: my($func) = $AUTOLOAD; >> /usr/perl5.8.8@RELEASE/lib/5.8.8/CGI.pm:847: my($pack,$func_name); >> /usr/perl5.8.8@RELEASE/lib/5.8.8/CGI.pm:849: local($1,$2); # this fixes an obscure variable suicide problem. >> /usr/perl5.8.8@RELEASE/lib/5.8.8/CGI.pm:849: local($1,$2); # this fixes an obscure variable suicide problem. >> /usr/perl5.8.8@RELEASE/lib/5.8.8/CGI.pm:850: $func=~/(.+)::([^:]+)$/; >> /usr/perl5.8.8@RELEASE/lib/5.8.8/CGI.pm:851: ($pack,$func_name) = ($1,$2); >> /usr/perl5.8.8@RELEASE/lib/5.8.8/CGI.pm:852: $pack=~s/::SUPER$//; # fix another obscure problem >> /usr/perl5.8.8@RELEASE/lib/5.8.8/CGI.pm:854: unless defined(${"$pack\:\:AUTOLOADED_ROUTINES"}); >> /usr/perl5.8.8@RELEASE/lib/5.8.8/CGI.pm:853: $pack = ${"$pack\:\:AutoloadClass"} || $CGI::DefaultClass >> /usr/perl5.8.8@RELEASE/lib/5.8.8/CGI.pm:856: my($sub) = \%{"$pack\:\:SUBS"}; >> /usr/perl5.8.8@RELEASE/lib/5.8.8/CGI.pm:856: my($sub) = \%{"$pack\:\:SUBS"}; >> /usr/perl5.8.8@RELEASE/lib/5.8.8/CGI.pm:857: unless (%$sub) { >> /usr/perl5.8.8@RELEASE/lib/5.8.8/CGI.pm:864: my($code) = $sub->{$func_name}; >> /usr/perl5.8.8@RELEASE/lib/5.8.8/CGI.pm:866: $code = "sub $AUTOLOAD { }" if (!$code and $func_name eq 'DESTROY'); >> /usr/perl5.8.8@RELEASE/lib/5.8.8/CGI.pm:867: if (!$code) { >> /usr/perl5.8.8@RELEASE/lib/5.8.8/CGI.pm:877: croak("Undefined subroutine $AUTOLOAD\n") unless $code; >> /usr/perl5.8.8@RELEASE/lib/5.8.8/CGI.pm:878: local ($@,$!); >> /usr/perl5.8.8@RELEASE/lib/5.8.8/CGI.pm:879: eval "package $pack; $code"; >> /usr/perl5.8.8@RELEASE/lib/5.8.8/CGI.pm:880: if ($@) { >> /usr/perl5.8.8@RELEASE/lib/5.8.8/CGI.pm:885: CORE::delete($sub->{$func_name}); #free storage >> /usr/perl5.8.8@RELEASE/lib/5.8.8/CGI.pm:886: return "$pack\:\:$func_name"; >> /usr/perl5.8.8@RELEASE/lib/5.8.8/CGI.pm:842: goto &$func; >> (eval 50)[/usr/perl5.8.8@RELEASE/lib/5.8.8/CGI.pm:879]:3: my($self, $buff) = @_; >> (eval 50)[/usr/perl5.8.8@RELEASE/lib/5.8.8/CGI.pm:879]:4: local $^W=0; # prevent a warning >> (eval 50)[/usr/perl5.8.8@RELEASE/lib/5.8.8/CGI.pm:879]:10: my($eoffound) = 0; >> (eval 50)[/usr/perl5.8.8@RELEASE/lib/5.8.8/CGI.pm:879]:11: my($localbuf) = ''; >> (eval 50)[/usr/perl5.8.8@RELEASE/lib/5.8.8/CGI.pm:879]:12: my($tempbuf) = ''; >> (eval 50)[/usr/perl5.8.8@RELEASE/lib/5.8.8/CGI.pm:879]:13: my($bufsiz) = 1024; >> (eval 50)[/usr/perl5.8.8@RELEASE/lib/5.8.8/CGI.pm:879]:14: my($res); >> (eval 50)[/usr/perl5.8.8@RELEASE/lib/5.8.8/CGI.pm:879]:15: while ($eoffound == 0) { >> (eval 50)[/usr/perl5.8.8@RELEASE/lib/5.8.8/CGI.pm:879]:16: if ( $MOD_PERL ) { >> (eval 50)[/usr/perl5.8.8@RELEASE/lib/5.8.8/CGI.pm:879]:20: $res = read(\*STDIN, $tempbuf, $bufsiz);
On Mon Aug 03 02:59:12 2009, SREZIC wrote: Show quoted text
> The t/30-controller-requests.t test hangs on my system (FreeBSD 7.0, > perl 5.8.8). Attached is the log created with perl -d:Trace. It seems > like at this point CGI is trying to read POST (?) content from STDIN. > > Regards, > Slaven
Thanks for this report, Slaven. Looks like an interaction with the latest CGI.pm 3.44 (3.43 is ok).
On Wed Aug 05 16:20:12 2009, RPETTETT wrote: Show quoted text
> On Mon Aug 03 02:59:12 2009, SREZIC wrote:
> > The t/30-controller-requests.t test hangs on my system (FreeBSD 7.0, > > perl 5.8.8). Attached is the log created with perl -d:Trace. It seems > > like at this point CGI is trying to read POST (?) content from STDIN. > > > > Regards, > > Slaven
> > > Thanks for this report, Slaven. Looks like an interaction with the > latest CGI.pm 3.44 (3.43 is ok).
Latest release seems to fix this issue. (Tied IO::Scalar to STDIN during tests)