In perl.git, the branch blead has been updated <http://perl5.git.perl.org/perl.git/commitdiff/94fa954eaae532928977ae7f7290536783269b6e?hp=73d3d06d86e1eead8f63e5190682ceacbaef8ac1>
- Log ----------------------------------------------------------------- commit 94fa954eaae532928977ae7f7290536783269b6e Author: Rafael Garcia-Suarez <[email protected]> Date: Wed Apr 21 15:47:36 2010 +0200 Fix [perl #74542] 5.12.0 crash on diverse platforms Filetest ops don't always expect an op on the stack, so we should use TOPs only if we're sure that we're not stat'ing the _ filehandle. This is indicated by OPf_KIDS (as checked in ck_ftst). ----------------------------------------------------------------------- Summary of changes: pp.h | 3 ++- 1 files changed, 2 insertions(+), 1 deletions(-) diff --git a/pp.h b/pp.h index 9d078af..c36502a 100644 --- a/pp.h +++ b/pp.h @@ -474,7 +474,8 @@ Does not use C<TARG>. See also C<XPUSHu>, C<mPUSHu> and C<PUSHu>. #define tryAMAGICftest(chr) \ STMT_START { \ assert(chr != '?'); \ - if (SvAMAGIC(TOPs)) { \ + if ((PL_op->op_flags & OPf_KIDS) \ + && SvAMAGIC(TOPs)) { \ const char tmpchr = (chr); \ SV * const tmpsv = amagic_call(TOPs, \ newSVpvn_flags(&tmpchr, 1, SVs_TEMP), \ -- Perl5 Master Repository
