core-cpan-diff: improve detection of version mismatches
authorDavid Golden <dagolden@cpan.org>
Mon, 19 Jul 2010 00:25:22 +0000 (20:25 -0400)
committerDavid Golden <dagolden@cpan.org>
Mon, 19 Jul 2010 00:25:22 +0000 (20:25 -0400)
Porting/core-cpan-diff

index 4e36035..c229bcb 100755 (executable)
@@ -318,7 +318,7 @@ EOF
             my $relative_mapped_file = $mapped_file;
             $relative_mapped_file =~ s/^(cpan|dist|ext)\/.*?\///;
 
-            for my $f ( catfile( 'lib', $main_pm ), $main_pm ) {
+            for my $f ( catfile( 'lib', $main_pm ), File::Basename::basename($main_pm) ) {
                 next unless $f eq $relative_mapped_file;
                 my $pv = MM->parse_version($mapped_file)   || '(unknown)';
                 my $cv = MM->parse_version($abs_cpan_file) || '(unknown)';