Re: Seg fault with HTML::Parser
The test case is now down to:
use HTML::Parser;
my $x = HTML::Parser->new(api_version => 3);
$x->handler(end => sub { push(@row, (1) x 505); 1 }, "");
$x->parse("</TD>");
When running it with 'perl -Dts' I get:
(xxx.pl:4) pushmark
=> \HV() PV("</TD>"\0) * AV() *
(xxx.pl:4) const(IV(1))
=> \HV() PV("</TD>"\0) * AV() * IV(1)
(xxx.pl:4) const(IV(505))
=> \HV() PV("</TD>"\0) * AV() * IV(1) IV(505)
(xxx.pl:4) repeat
=> ... IV(1) IV(1) IV(1) IV(1) IV(1) IV(1) IV(1) IV(1) IV(1) IV(1) IV(1) IV(1) IV(1)
IV(1) IV(1) IV(1) IV(1) IV(1) IV(1) IV(1) IV(1) IV(1) IV(1) IV(1) IV(1) IV(1) IV(1) IV(1) IV(1) IV(1)
(xxx.pl:4) push
=> \HV() PV("</TD>"\0) IV(505)
(xxx.pl:4) leavesub
=> [STACK UNDERFLOW!!!]
(xxx.pl:5) leave
=> \HV()
(xxx.pl:0) nextstate
=>
The [STACK UNDERFLOW!!!] part seems pretty bad. If I only push 504
elements onto @row things look ok.
Reply to: