Change 20079 by [EMAIL PROTECTED] on 2003/07/08 20:26:20

        The CHECKOP macro was not invoked on some newly created ops
        (to match them against the current opmask.) As a consequence,
        Safe compartments were unable to trap some ops (pattern
        match, slices, conditionals.) This fixes the holes.

Affected files ...

... //depot/perl/op.c#577 edit

Differences ...

==== //depot/perl/op.c#577 (text) ====
Index: perl/op.c
--- perl/op.c#576~20076~        Tue Jul  8 10:39:49 2003
+++ perl/op.c   Tue Jul  8 13:26:20 2003
@@ -2174,7 +2174,7 @@
            listop->op_last = pushop;
     }
 
-    return (OP*)listop;
+    return CHECKOP(type, listop);
 }
 
 OP *
@@ -2611,7 +2611,7 @@
        PmopSTASH_set(pmop,PL_curstash);
     }
 
-    return (OP*)pmop;
+    return CHECKOP(type, pmop);
 }
 
 OP *
@@ -3417,6 +3417,8 @@
     first->op_next = (OP*)logop;
     first->op_sibling = other;
 
+    CHECKOP(type,logop);
+
     o = newUNOP(OP_NULL, 0, (OP*)logop);
     other->op_next = o;
 
@@ -3461,6 +3463,8 @@
     logop->op_other = LINKLIST(trueop);
     logop->op_next = LINKLIST(falseop);
 
+    CHECKOP(OP_COND_EXPR, /* that's logop->op_type */
+           logop);
 
     /* establish postfix order */
     start = LINKLIST(first);
End of Patch.

Reply via email to