From: Rick Delaney Date: Sun, 4 Aug 2002 00:28:58 +0000 (-0400) Subject: Re: [PATCH] Re: taint news X-Git-Url: http://git.shadowcat.co.uk/gitweb/gitweb.cgi?a=commitdiff_plain;h=5a445156505b2b63705ed94cffed69b6c031ee2c;p=p5sagit%2Fp5-mst-13.2.git Re: [PATCH] Re: taint news Message-ID: Ref: 20020208.005 p4raw-id: //depot/perl@17676 --- diff --git a/pp_sys.c b/pp_sys.c index bd2334a..7a44b6b 100644 --- a/pp_sys.c +++ b/pp_sys.c @@ -4048,24 +4048,14 @@ PP(pp_system) I32 did_pipes = 0; if (PL_tainting) { - int some_arg_tainted = 0; TAINT_ENV(); while (++MARK <= SP) { (void)SvPV_nolen(*MARK); /* stringify for taint check */ - if (PL_tainted) { - some_arg_tainted = 1; + if (PL_tainted) break; - } } MARK = ORIGMARK; - /* XXX Remove warning at end of deprecation cycle --RD 2002-02 */ - if (SP - MARK == 1) { - TAINT_PROPER("system"); - } - else if (some_arg_tainted && ckWARN2(WARN_TAINT, WARN_DEPRECATED)) { - Perl_warner(aTHX_ packWARN2(WARN_TAINT, WARN_DEPRECATED), - "Use of tainted arguments in %s is deprecated", "system"); - } + TAINT_PROPER("system"); } PERL_FLUSHALL_FOR_CHILD; #if (defined(HAS_FORK) || defined(AMIGAOS)) && !defined(VMS) && !defined(OS2) || defined(PERL_MICRO) @@ -4186,24 +4176,14 @@ PP(pp_exec) STRLEN n_a; if (PL_tainting) { - int some_arg_tainted = 0; TAINT_ENV(); while (++MARK <= SP) { (void)SvPV_nolen(*MARK); /* stringify for taint check */ - if (PL_tainted) { - some_arg_tainted = 1; + if (PL_tainted) break; - } } MARK = ORIGMARK; - /* XXX Remove warning at end of deprecation cycle --RD 2002-02 */ - if (SP - MARK == 1) { - TAINT_PROPER("exec"); - } - else if (some_arg_tainted && ckWARN2(WARN_TAINT, WARN_DEPRECATED)) { - Perl_warner(aTHX_ packWARN2(WARN_TAINT, WARN_DEPRECATED), - "Use of tainted arguments in %s is deprecated", "exec"); - } + TAINT_PROPER("exec"); } PERL_FLUSHALL_FOR_CHILD; if (PL_op->op_flags & OPf_STACKED) {