Don't warn on use of CCFLAGS
[p5sagit/p5-mst-13.2.git] / pp_sys.c
index a1229e5..75fdc40 100644 (file)
--- a/pp_sys.c
+++ b/pp_sys.c
@@ -154,12 +154,13 @@ PP(pp_backtick)
     TAINT_PROPER("``");
     fp = my_popen(tmps, "r");
     if (fp) {
-       sv_setpv(TARG, "");     /* note that this preserves previous buffer */
        if (GIMME == G_SCALAR) {
+           sv_setpv(TARG, ""); /* note that this preserves previous buffer */
            while (sv_gets(TARG, fp, SvCUR(TARG)) != Nullch)
                /*SUPPRESS 530*/
                ;
            XPUSHs(TARG);
+           SvTAINTED_on(TARG);
        }
        else {
            SV *sv;
@@ -175,9 +176,11 @@ PP(pp_backtick)
                    SvLEN_set(sv, SvCUR(sv)+1);
                    Renew(SvPVX(sv), SvLEN(sv), char);
                }
+               SvTAINTED_on(sv);
            }
        }
        STATUS_NATIVE_SET(my_pclose(fp));
+       TAINT;          /* "I believe that this is not gratuitous!" */
     }
     else {
        STATUS_NATIVE_SET(-1);
@@ -2946,7 +2949,7 @@ PP(pp_system)
        STATUS_NATIVE_SET(result == -1 ? -1 : status);
        do_execfree();  /* free any memory child malloced on vfork */
        SP = ORIGMARK;
-       PUSHi(STATUS_POSIX);
+       PUSHi(STATUS_CURRENT);
        RETURN;
     }
     if (op->op_flags & OPf_STACKED) {
@@ -2972,7 +2975,7 @@ PP(pp_system)
     STATUS_NATIVE_SET(value);
     do_execfree();
     SP = ORIGMARK;
-    PUSHi(STATUS_POSIX);
+    PUSHi(STATUS_CURRENT);
 #endif /* !FORK or VMS */
     RETURN;
 }
@@ -3048,7 +3051,7 @@ PP(pp_getpgrp)
 #ifdef BSD_GETPGRP
     value = (I32)BSD_GETPGRP(pid);
 #else
-    if (pid != 0 && pid != getpid()) {
+    if (pid != 0 && pid != getpid())
        DIE("POSIX getpgrp can't take an argument");
     value = (I32)getpgrp();
 #endif
@@ -3078,9 +3081,8 @@ PP(pp_setpgrp)
 #ifdef BSD_SETPGRP
     SETi( BSD_SETPGRP(pid, pgrp) >= 0 );
 #else
-    if ((pgrp != 0 && pgrp != getpid())) || (pid != 0 && pid != getpid())) {
+    if ((pgrp != 0 && pgrp != getpid())) || (pid != 0 && pid != getpid()))
        DIE("POSIX setpgrp can't take an argument");
-    }
     SETi( setpgrp() >= 0 );
 #endif /* USE_BSDPGRP */
     RETURN;