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

[SCM] Debian package checker branch, master, updated. 2.2.10-99-gc0aea40



The following commit has been merged in the master branch:
commit c0aea40c3e3fd4366e9683a14acaae6acda13522
Author: Adam D. Barratt <adam@adam-barratt.org.uk>
Date:   Fri Jun 12 21:21:52 2009 +0100

    Correctly display package versions of 0 in status messages
    
    * lib/Lintian/Schedule.pm:
      + [ADB] Correctly display package versions of 0 in status messages.
        (Closes: #532550)

diff --git a/debian/changelog b/debian/changelog
index 9bb337f..62a0710 100755
--- a/debian/changelog
+++ b/debian/changelog
@@ -131,6 +131,9 @@ lintian (2.2.11) UNRELEASED; urgency=low
     + [ADB] Rework to use libapt-pkg-perl rather than calling "dpkg
       --compare-versions" repeatedly and keeping a potentially large
       cache of previous results.
+  * lib/Lintian/Schedule.pm:
+    + [ADB] Correctly display package versions of 0 in status messages.
+      (Closes: #532550)
   * lib/scan_script.pl:
     + [RA] Removed.  A start at parsing shell scripts that was never
       finished and wasn't usable in its current form.
diff --git a/lib/Lintian/Schedule.pm b/lib/Lintian/Schedule.pm
index 3fe5899..bb71839 100644
--- a/lib/Lintian/Schedule.pm
+++ b/lib/Lintian/Schedule.pm
@@ -49,7 +49,8 @@ sub add_file {
 	    @pkg_info{qw(package version architecture)};
     }
     $pkg  ||= '';
-    $ver  ||= '';
+    # "0" is a valid version, so we can't use || here
+    $ver  = '' unless length $ver;
     $arch ||= '';
 
     my $s = "$type $pkg $ver $arch $file";
diff --git a/t/source/package-version-0/Makefile b/t/source/package-version-0/Makefile
new file mode 100644
index 0000000..8c4d20c
--- /dev/null
+++ b/t/source/package-version-0/Makefile
@@ -0,0 +1,13 @@
+name = package-version-0
+dir  = $(name)-0
+
+all:
+	mkdir $(dir)
+	mkdir $(dir)/debian
+	cp changelog copyright control rules $(dir)/debian/
+	echo 7 > $(dir)/debian/compat
+	dpkg-source -sn -b $(dir)
+
+clean:
+	rm -rf $(dir)
+	rm -f $(name)_0*
diff --git a/t/source/package-version-0/changelog b/t/source/package-version-0/changelog
new file mode 100644
index 0000000..c3d8902
--- /dev/null
+++ b/t/source/package-version-0/changelog
@@ -0,0 +1,9 @@
+package-version-0 (0) unstable; urgency=low
+
+  * Lintian Test Suite.
+  * Test: package-version-0
+
+  * Suppress "should close ITP bug" messages.  (Closes: #123456)
+
+ -- Debian Lintian Maintainers <lintian-maint@debian.org>  Fri, 12 Jun 2009 21:08:23 +0100
+
diff --git a/t/source/cruft-ancient-file/control b/t/source/package-version-0/control
similarity index 72%
copy from t/source/cruft-ancient-file/control
copy to t/source/package-version-0/control
index f1cfc89..37ee29d 100644
--- a/t/source/cruft-ancient-file/control
+++ b/t/source/package-version-0/control
@@ -1,14 +1,15 @@
-Source: cruft-ancient-file
+Source: package-version-0
 Section: devel
 Priority: optional
 Maintainer: Debian Lintian Maintainers <lintian-maint@debian.org>
 Build-Depends: debhelper (>= 7)
-Standards-Version: 3.8.0
+Standards-Version: 3.8.1
 
-Package: cruft-ancient-file
+Package: package-version-0
 Architecture: all
 Depends: ${misc:Depends}
-Description: Test package for ancient files producing tar errors
+Description: Test for package versions of "0"
  This is a test package designed to exercise some feature or tag of
  Lintian.  It is part of the Lintian test suite and may do very odd
  things.  It should not be installed like a regular package.
+
diff --git a/t/debs/deb-format-ancient-file/copyright b/t/source/package-version-0/copyright
similarity index 94%
copy from t/debs/deb-format-ancient-file/copyright
copy to t/source/package-version-0/copyright
index 98298fd..6afc448 100644
--- a/t/debs/deb-format-ancient-file/copyright
+++ b/t/source/package-version-0/copyright
@@ -3,6 +3,7 @@ in the lintian source directory for more details.
 
 So far as it is copyrightable at all, this test case is
    Copyright © 2009 Russ Allbery <rra@debian.org>
+   Copyright © 2009 Adam D. Barratt <adam@adam-barratt.org.uk>
 
 This program is free software; you may redistribute it and/or modify
 it under the terms of the GNU General Public License as published by
diff --git a/t/source/cruft-ancient-file/rules b/t/source/package-version-0/rules
similarity index 100%
copy from t/source/cruft-ancient-file/rules
copy to t/source/package-version-0/rules
diff --git a/t/debs/deb-format-record-size/tags b/t/source/package-version-0/tags
similarity index 100%
copy from t/debs/deb-format-record-size/tags
copy to t/source/package-version-0/tags

-- 
Debian package checker


Reply to: