diff options
author | Larry Wall <larry@netlabs.com> | 1994-03-18 00:00:00 +0000 |
---|---|---|
committer | Larry Wall <larry@netlabs.com> | 1994-03-18 00:00:00 +0000 |
commit | 8990e3071044a96302560bbdb5706f3e74cf1bef (patch) | |
tree | 6cf4a58108544204591f25bd2d4f1801d49334b4 /taint.c | |
parent | ed6116ce9b9d13712ea252ee248b0400653db7f9 (diff) | |
download | perl-8990e3071044a96302560bbdb5706f3e74cf1bef.tar.gz |
perl 5.0 alpha 6
[editor's note: cleaned up from the September '94 InfoMagic CD, just
like the last commit]
Diffstat (limited to 'taint.c')
-rw-r--r-- | taint.c | 5 |
1 files changed, 3 insertions, 2 deletions
@@ -42,10 +42,11 @@ taint_env() SV** svp; if (tainting) { + MAGIC *mg = 0; svp = hv_fetch(GvHVn(envgv),"PATH",4,FALSE); - if (!svp || *svp == &sv_undef || mg_find(*svp, 't')) { + if (!svp || *svp == &sv_undef || (mg = mg_find(*svp, 't'))) { tainted = 1; - if (SvPRIVATE(*svp) & SVp_TAINTEDDIR) + if (mg && MgTAINTEDDIR(mg)) taint_proper("Insecure directory in %s%s", "PATH"); else taint_proper("Insecure %s%s", "PATH"); |