[SCM] Debian package checker branch, infra-513663, updated. 2.5.0-rc1-104-g271ae48
The following commit has been merged in the infra-513663 branch:
commit 271ae48d89cc897822d858fcab587fb1f1dade82
Author: Niels Thykier <niels@thykier.net>
Date: Tue Mar 29 19:53:08 2011 +0200
Fix the way L::P figures out the name of a changes file
diff --git a/lib/Lintian/Processable.pm b/lib/Lintian/Processable.pm
index 65bb832..6b489c1 100644
--- a/lib/Lintian/Processable.pm
+++ b/lib/Lintian/Processable.pm
@@ -162,16 +162,8 @@ sub _init{
$self->{pkg_src_version} = $pkg_version;
} elsif ($pkg_type eq 'changes'){
my $cinfo = get_dsc_info ($pkg_path) or fail "$pkg_path is not a valid changes file";
- my $pkg_name = $pkg_path;
+ my $pkg_name = ($pkg_path =~ m,.*/([^/]+)\.changes,);
my $pkg_version = $cinfo->{version};
- $pkg_name =~ s,.*/,,og; # strip directories (if any)
- if ($pkg_name =~ m/_/o){
- # regular named changes file
- $pkg_name =~ s,^([^/_]+)_[^/]+\.changes$,$1,;
- } else {
- # irregular changes file (e.g. some of our tests trigger this)
- $pkg_name =~ s,\.changes$,,o;
- }
$self->{pkg_name} = $pkg_name;
$self->{pkg_version} = $pkg_version;
$self->{pkg_src} = $cinfo->{source}//$pkg_name;
--
Debian package checker
Reply to: