[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

[SCM] Debian package checker branch, master, updated. 2.5.3-19-g890284d



The following commit has been merged in the master branch:
commit 890284d10be0994e1f14093992a2238bb3c4184b
Author: Niels Thykier <niels@thykier.net>
Date:   Sun Sep 18 18:26:54 2011 +0200

    checks/cruft: escape paths used in regexes
    
    This solves an issue, where the path of the Lintian Lab is
    included in some tag extra.
    
    Signed-off-by: Niels Thykier <niels@thykier.net>

diff --git a/checks/cruft b/checks/cruft
index 664c0d3..6e7a6d7 100644
--- a/checks/cruft
+++ b/checks/cruft
@@ -121,12 +121,13 @@ my $ltinbd  = $info->relation('build-depends-all')->implies('libtool');
 my %warned;
 my $format = $info->field('format');
 if ($format =~ /^\s*2\.0\s*\z/ or $format =~ /^\s*3\.0\s*\(quilt\)/) {
-    my $wanted = sub { check_debfiles($pkg, $info, $droot, \%warned) };
+    my $wanted = sub { check_debfiles($pkg, $info, qr/\Q$droot\E/, \%warned) };
     find($wanted, $droot);
 } elsif (not $info->native) {
     check_diffstat($info->diffstat, \%warned);
 }
-my $wanted = sub { find_cruft($pkg, $info, $info->unpacked, \%warned, $atdinbd, $ltinbd) };
+my $uroot = $info->unpacked;
+my $wanted = sub { find_cruft($pkg, $info, qr/\Q$uroot\E/, \%warned, $atdinbd, $ltinbd) };
 find($wanted, $info->unpacked);
 
 # Look for cruft based on file's results, but allow cruft in test directories
diff --git a/debian/changelog b/debian/changelog
index 5a767e6..ea4c4c2 100644
--- a/debian/changelog
+++ b/debian/changelog
@@ -1,5 +1,7 @@
 lintian (2.5.4) UNRELEASED; urgency=low
 
+  * checks/cruft:
+    + [NT] Escape path when using them in regexes.
   * checks/dehelper:
     + [JW,NT] Check for versioned dependencies for some dh_commands.
       (Closes: #641035)

-- 
Debian package checker


Reply to: