From: Zefram Date: Thu, 26 Nov 2009 15:19:09 +0000 (+0000) Subject: -Dmad minitest failure bisect X-Git-Url: http://git.shadowcat.co.uk/gitweb/gitweb.cgi?a=commitdiff_plain;h=9735c8aa020a58992ffadba440014d200222da56;p=p5sagit%2Fp5-mst-13.2.git -Dmad minitest failure bisect Tony Cook wrote: >Smokes with -Dmad have been failing during make minitest since the >middle of last month. Mostly fixed by the attached patch. The fault is a logic error on my part, probably from the early phase of developing the lexer API patch, when I didn't properly understand the various buffer pointer variables. In my tests with -Dmad, I'm still getting a test failure ("panic: input overflow") from t/op/incfilter.t. The underlying problem is the filter layer mishandling things when a filter function gives it a multiline string, so it generates an invalid SV state (strlen(SvPVX(PL_linestr)) > SvCUR(PL_linestr)). This faulty state also occurs without -Dmad, and so doesn't appear to be Mad-related, it just doesn't in practice cause the test panic without -Dmad. I'm investigating this bug now. -zefram Signed-off-by: H.Merijn Brand --- diff --git a/toke.c b/toke.c index 72fc10b..173ded4 100644 --- a/toke.c +++ b/toke.c @@ -1201,9 +1201,6 @@ Perl_lex_next_chunk(pTHX_ U32 flags) bool got_some; if (flags & ~(LEX_KEEP_PREVIOUS|LEX_FAKE_EOF)) Perl_croak(aTHX_ "Lexing code internal error (%s)", "lex_next_chunk"); -#ifdef PERL_MAD - flags |= LEX_KEEP_PREVIOUS; -#endif /* PERL_MAD */ linestr = PL_parser->linestr; buf = SvPVX(linestr); if (!(flags & LEX_KEEP_PREVIOUS) &&