In perl.git, the branch blead has been updated

<http://perl5.git.perl.org/perl.git/commitdiff/b8de32d59998a5999bfdf82297af4ccc75421091?hp=20a4c497f5b0005c2471e3b5ae0d1bb1744fa871>

- Log -----------------------------------------------------------------
commit b8de32d59998a5999bfdf82297af4ccc75421091
Author: Alex Vandiver <ale...@mit.edu>
Date:   Thu May 28 16:27:25 2009 -0400

    Fix [RT#66098] -- stricter checking on SvIVX exposed a lack of SvIOK check
-----------------------------------------------------------------------

Summary of changes:
 op.c         |    2 +-
 t/op/split.t |    8 +++++++-
 2 files changed, 8 insertions(+), 2 deletions(-)

diff --git a/op.c b/op.c
index 8851c06..7488887 100644
--- a/op.c
+++ b/op.c
@@ -4325,7 +4325,7 @@ Perl_newASSIGNOP(pTHX_ I32 flags, OP *left, I32 optype, 
OP *right)
                      ((LISTOP*)right)->op_last->op_type == OP_CONST)
                    {
                        SV *sv = ((SVOP*)((LISTOP*)right)->op_last)->op_sv;
-                       if (SvIVX(sv) == 0)
+                       if (SvIOK(sv) && SvIVX(sv) == 0)
                            sv_setiv(sv, PL_modcount+1);
                    }
                }
diff --git a/t/op/split.t b/t/op/split.t
index 025327f..b3a9741 100755
--- a/t/op/split.t
+++ b/t/op/split.t
@@ -6,7 +6,7 @@ BEGIN {
     require './test.pl';
 }
 
-plan tests => 135;
+plan tests => 136;
 
 $FS = ':';
 
@@ -358,3 +358,9 @@ ok(@ary == 3 &&
     is($s[2]," XYZ");
     is(join(':',@s), join(':',@r));
 }
+
+{
+    use constant BANG => {};
+    () = split m/,/, "", BANG;
+    ok(1);
+}

--
Perl5 Master Repository

Reply via email to