...while $var = glob(...)
Robin Houston [Mon, 17 Dec 2001 15:51:54 +0000 (15:51 +0000)]
Message-ID: <20011217155153.A311@robin.kitsite.com>

p4raw-id: //depot/perl@13738

op.c

diff --git a/op.c b/op.c
index cb891c4..a35c919 100644 (file)
--- a/op.c
+++ b/op.c
@@ -4073,7 +4073,7 @@ Perl_newLOOPOP(pTHX_ I32 flags, I32 debuggable, OP *expr, OP *block)
              case OP_SASSIGN:
                if (k1->op_type == OP_READDIR
                      || k1->op_type == OP_GLOB
-                     || (k1->op_type == OP_NULL && k1->op_targ == OP_NULL)
+                     || (k1->op_type == OP_NULL && k1->op_targ == OP_GLOB)
                      || k1->op_type == OP_EACH)
                    expr = newUNOP(OP_DEFINED, 0, expr);
                break;