This is a live mirror of the Perl 5 development currently hosted at
https://github.com/perl/perl5
https://perl5.git.perl.org
/
perl5.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
a6d5524
)
Protect against localizing an %ENV slice.
author
Rafael Garcia-Suarez
<rgarciasuarez@gmail.com>
Mon, 3 Jun 2002 19:15:26 +0000
(19:15 +0000)
committer
Rafael Garcia-Suarez
<rgarciasuarez@gmail.com>
Mon, 3 Jun 2002 19:15:26 +0000
(19:15 +0000)
p4raw-id: //depot/perl@16982
lib/Cwd.pm
patch
|
blob
|
blame
|
history
diff --git
a/lib/Cwd.pm
b/lib/Cwd.pm
index
8b00543
..
24ad1e2
100644
(file)
--- a/
lib/Cwd.pm
+++ b/
lib/Cwd.pm
@@
-196,7
+196,11
@@
$pwd_cmd ||= 'pwd';
# The 'natural and safe form' for UNIX (pwd may be setuid root)
sub _backtick_pwd {
- local @ENV{qw(PATH IFS CDPATH ENV BASH_ENV)};
+ local $ENV{PATH};
+ local $ENV{IFS};
+ local $ENV{CDPATH};
+ local $ENV{ENV};
+ local $ENV{BASH_ENV};
my $cwd = `$pwd_cmd`;
# Belt-and-suspenders in case someone said "undef $/".
local $/ = "\n";