diff options
author | Jan Dubois <jand@activestate.com> | 2010-11-25 16:26:51 -0800 |
---|---|---|
committer | Jan Dubois <jand@activestate.com> | 2010-11-25 16:26:51 -0800 |
commit | d4456f896c3eddd615abf6048839581863ea6ca3 (patch) | |
tree | 416b1a4152de8bc4c100295ae447efb3c18a4686 /t/op | |
parent | c788c1c2f78983cf6d561b2809d959be4999c7e7 (diff) | |
download | perl-d4456f896c3eddd615abf6048839581863ea6ca3.tar.gz |
Can't spawn fresh Perl interpreter with an empty PATH
Diffstat (limited to 't/op')
-rw-r--r-- | t/op/taint.t | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/t/op/taint.t b/t/op/taint.t index 86372bd1f4..0decc97461 100644 --- a/t/op/taint.t +++ b/t/op/taint.t @@ -1397,6 +1397,14 @@ foreach my $ord (78, 163, 256) { } { + # On Windows we can't spawn a fresh Perl interpreter unless at + # least the Windows system directory (usually C:\Windows\System32) + # is still on the PATH. There is however no way to determine the + # actual path on the current system without loading the Win32 + # module, so we just restore the original $ENV{PATH} here. + local $ENV{PATH} = $ENV{PATH}; + $ENV{PATH} = $old_env_path if $Is_MSWin32; + fresh_perl_is(<<'end', "ok", { switches => [ '-T' ] }, $TAINT = substr($^X, 0, 0); formline('@'.('<'x("2000".$TAINT)).' | @*', 'hallo', 'welt'); |