Subject: | CPAN::Site::Index::inspect_archive() sometimes passes incorrect value to package_on_usual_location() |
In CPAN::Site::Index around lines 192/193:
$file->is_file && $fn =~ m/\.pm$/i && package_on_usual_location $fn
or next;
the value $fn will sometimes not be correct, because of differences in
how the tarball was created. Sometimes $fn will have only the file name
when it should have a longer path (relative to the top of the tarball.)
$fn comes from:
$file->name
where $file is an Achive::Tar::File object.
It would be better if the value passed to package_on_usual_location() was
$file->full_path
for example:
190 foreach my $file ($arch->get_files)
191 { my $fn = $file->full_path;
192 $file->is_file && $fn =~ m/\.pm$/i &&
package_on_usual_location $fn
193 or next;
194 collect_package_details $dist, $file;
195 }