summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorNicholas Clark <nick@ccl4.org>2012-02-07 17:18:36 +0100
committerNicholas Clark <nick@ccl4.org>2012-02-07 17:18:36 +0100
commit75d90f49c26dc33955d848d3586b4a7fe2136cf6 (patch)
tree2baa9ab9160685133b8cd771a2e67552d99d6937
parentb069bc5e4376bcbd50b97f34a027cf3048d3c202 (diff)
downloadperl-smoke-me/blead.tar.gz
is_duplicate_pod() and get_pod_metadata() in pod_lib.pl modified $_smoke-me/blead
Reported by Reini Urban in RT #110078, installperl generated a warning and failed to install CORE.pod, because is_duplicate_pod() modified $_ is_duplicate_pod() and get_pod_metadata() now both localise $_, to ensure that they don't corrupt any caller's state.
-rw-r--r--Porting/pod_lib.pl2
1 files changed, 2 insertions, 0 deletions
diff --git a/Porting/pod_lib.pl b/Porting/pod_lib.pl
index c86993d133..98c32f4565 100644
--- a/Porting/pod_lib.pl
+++ b/Porting/pod_lib.pl
@@ -86,6 +86,7 @@ my %state = (
sub is_duplicate_pod {
my $file = shift;
+ local $_;
# Initialise the list of possible source files on the first call.
unless (%Lengths) {
@@ -229,6 +230,7 @@ sub get_pod_metadata {
my $permit_missing_generated = shift;
# Do they want a consistency report?
my $callback = shift;
+ local $_;
__prime_state() unless $state{master};
return \%state unless $callback;