The following commit has been merged in the master branch:
commit 2f5a4b8e9aff5ad463a3b994b2480f44119cbcc3
Author: Raphael Geissert <[email protected]>
Date:   Thu Apr 9 09:48:32 2009 -0500

    Anchor the gz-file-not-gzip regex to avoid false positives on 
foo.gzbar-like files

diff --git a/checks/files b/checks/files
index 34178af..897c965 100644
--- a/checks/files
+++ b/checks/files
@@ -761,7 +761,7 @@ foreach my $file (sort keys %{$info->index}) {
        }
 
        # ---------------- .gz files
-       if ($file =~ m/\.gz/) {
+       if ($file =~ m/\.gz$/) {
            my $info = $info->file_info->{$file} || '';
            if ($info !~ m/gzip compressed/) {
                tag "gz-file-not-gzip", "$file";
diff --git a/t/tests/files-gzip/debian/debian/install 
b/t/tests/files-gzip/debian/debian/install
index 2ba1ce3..cfd0b7d 100644
--- a/t/tests/files-gzip/debian/debian/install
+++ b/t/tests/files-gzip/debian/debian/install
@@ -1 +1 @@
-*.gz etc/
+*.gz* etc/
diff --git a/t/tests/files-gzip/upstream/unrelated.gz.txt 
b/t/tests/files-gzip/upstream/unrelated.gz.txt
new file mode 100644
index 0000000..de40891
--- /dev/null
+++ b/t/tests/files-gzip/upstream/unrelated.gz.txt
@@ -0,0 +1 @@
+Only .gz$ files should match, not .gzip, nor .gz.xxxx

-- 
Debian package checker


-- 
To UNSUBSCRIBE, email to [email protected]
with a subject of "unsubscribe". Trouble? Contact [email protected]

Reply via email to