From 4f0c3569a00842f5e61acf5180b4bb54744298e5 Mon Sep 17 00:00:00 2001 From: Graham Knop Date: Wed, 21 Feb 2024 10:33:11 +0100 Subject: [PATCH] avoid warnings under -w when checking for relocatable paths It is possible for exp keys in Config to be undef, and when running under -w it would produce warnings when regexing that undef. --- lib/ExtUtils/Packlist.pm | 1 + 1 file changed, 1 insertion(+) diff --git a/lib/ExtUtils/Packlist.pm b/lib/ExtUtils/Packlist.pm index 5fa93ff..4fa6603 100644 --- a/lib/ExtUtils/Packlist.pm +++ b/lib/ExtUtils/Packlist.pm @@ -46,6 +46,7 @@ sub __find_relocations while (my ($raw_key, $raw_val) = each %Config) { my $exp_key = $raw_key . "exp"; next unless exists $Config{$exp_key}; + next unless defined $raw_val; next unless $raw_val =~ m!\.\.\./!; $paths{$Config{$exp_key}}++; }