diff options
author | Ricardo Signes <rjbs@semiotic.systems> | 2022-10-25 21:49:16 -0400 |
---|---|---|
committer | Ricardo Signes <rjbs@semiotic.systems> | 2022-10-25 21:49:16 -0400 |
commit | 9439f2e54cec6de67ba8b480dc85c665eb06bded (patch) | |
tree | d2e368f444ce63df546cfd7466b6f33f4122c314 | |
parent | cb83daa0e4673ef10d314a69a847d335c7757da1 (diff) |
absolutize local directory
responding to a bug report from schmorp
-rw-r--r-- | lib/CPAN/Mini.pm | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/lib/CPAN/Mini.pm b/lib/CPAN/Mini.pm index fad858f..ffa703b 100644 --- a/lib/CPAN/Mini.pm +++ b/lib/CPAN/Mini.pm @@ -293,6 +293,8 @@ sub new { substr($self->{local}, 0, 1, $class->__homedir) if substr($self->{local}, 0, 1) eq q{~}; + $self->{local} = File::Spec->rel2abs($self->{local}); + Carp::croak "local mirror path exists but is not a directory" if (-e $self->{local}) and not(-d $self->{local}); |