Skip processing a file if the file to be opened is '-'
[p5sagit/p5-mst-13.2.git] / pp.c
diff --git a/pp.c b/pp.c
index c04d7b2..f33857c 100644 (file)
--- a/pp.c
+++ b/pp.c
@@ -254,7 +254,7 @@ PP(pp_rv2gv)
                            }
                        }
                    }
-                   gv_init(gv, PL_curcop->cop_stash, name, len, 0);
+                   gv_init(gv, CopSTASH(PL_curcop), name, len, 0);
                    sv_upgrade(sv, SVt_RV);
                    SvRV(sv) = (SV *) gv;
                    SvROK_on(sv);
@@ -581,7 +581,7 @@ PP(pp_bless)
     HV *stash;
 
     if (MAXARG == 1)
-       stash = PL_curcop->cop_stash;
+       stash = CopSTASH(PL_curcop);
     else {
        SV *ssv = POPs;
        STRLEN len;
@@ -3254,13 +3254,13 @@ PP(pp_unpack)
     I16 ashort;
     int aint;
     I32 along;
-#ifdef Quad_t
+#ifdef HAS_QUAD
     Quad_t aquad;
 #endif
     U16 aushort;
     unsigned int auint;
     U32 aulong;
-#ifdef Quad_t
+#ifdef HAS_QUAD
     Uquad_t auquad;
 #endif
     char *aptr;
@@ -4018,7 +4018,7 @@ PP(pp_unpack)
                sv_setpvn(sv, aptr, len);
            PUSHs(sv_2mortal(sv));
            break;
-#ifdef Quad_t
+#ifdef HAS_QUAD
        case 'q':
            along = (strend - s) / sizeof(Quad_t);
            if (len > along)
@@ -4336,7 +4336,7 @@ PP(pp_pack)
     unsigned int auint;
     I32 along;
     U32 aulong;
-#ifdef Quad_t
+#ifdef HAS_QUAD
     Quad_t aquad;
     Uquad_t auquad;
 #endif
@@ -4828,7 +4828,7 @@ PP(pp_pack)
                }
            }
            break;
-#ifdef Quad_t
+#ifdef HAS_QUAD
        case 'Q':
            while (len-- > 0) {
                fromstr = NEXTFROM;
@@ -4843,7 +4843,7 @@ PP(pp_pack)
                sv_catpvn(cat, (char*)&aquad, sizeof(Quad_t));
            }
            break;
-#endif /* Quad_t */
+#endif
        case 'P':
            len = 1;            /* assume SV is correct length */
            /* FALL THROUGH */
@@ -4938,8 +4938,13 @@ PP(pp_split)
     TAINT_IF((pm->op_pmflags & PMf_LOCALE) &&
             (pm->op_pmflags & (PMf_WHITE | PMf_SKIPWHITE)));
 
-    if (pm->op_pmreplroot)
+    if (pm->op_pmreplroot) {
+#ifdef USE_ITHREADS
+       ary = GvAVn((GV*)PL_curpad[(PADOFFSET)pm->op_pmreplroot]);
+#else
        ary = GvAVn((GV*)pm->op_pmreplroot);
+#endif
+    }
     else if (gimme != G_ARRAY)
 #ifdef USE_THREADS
        ary = (AV*)PL_curpad[0];