summaryrefslogtreecommitdiff
path: root/configpm
diff options
context:
space:
mode:
authorNicholas Clark <nick@ccl4.org>2005-06-25 17:58:26 +0000
committerNicholas Clark <nick@ccl4.org>2005-06-25 17:58:26 +0000
commit938af39eb5ebb494561ab6e53d6e8b8aa2d36adf (patch)
tree0e807b7a4078fcc54bf33132e05dae69efe98a5c /configpm
parentbc961b003e8925ea1668627dcdfb26c75212b4c6 (diff)
downloadperl-938af39eb5ebb494561ab6e53d6e8b8aa2d36adf.tar.gz
Add a sanity check to Config::AUTOLOAD to prevent infinte loops if
Configure_heavy.pl gets truncated. p4raw-id: //depot/perl@24982
Diffstat (limited to 'configpm')
-rwxr-xr-xconfigpm4
1 files changed, 3 insertions, 1 deletions
diff --git a/configpm b/configpm
index ab26eefe40..728e012d64 100755
--- a/configpm
+++ b/configpm
@@ -617,13 +617,15 @@ if ($Common{byteorder}) {
}
my $fast_config = join '', map { " $_,\n" } sort values %Common;
+# Sanity check needed to stop an infite loop if Config_heavy.pl fails to define
+# &launcher for some reason (eg it got truncated)
print CONFIG sprintf <<'ENDOFTIE', $fast_config;
sub DESTROY { }
sub AUTOLOAD {
require 'Config_heavy.pl';
- goto \&launcher;
+ goto \&launcher unless $Config::AUTOLOAD =~ /launcher$/;
die "&Config::AUTOLOAD failed on $Config::AUTOLOAD";
}