Package: lintian Version: 2.5.13 Hi,
New patch here
From 98565f6c75c92d08c47987628601aaafe93881e1 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Bastien=20ROUCARI=C3=88S?= <roucaries.bast...@gmail.com> Date: Sat, 15 Jun 2013 17:11:34 +0200 Subject: [PATCH 1/3] Fix another false positive for gfdl variant Fix another false positive when front-cover text is abbreviated front-cover. --- checks/cruft.pm | 4 ++-- .../debian/src/oldfalsepositive/mailutils.texi | 6 ++++++ 2 files changed, 8 insertions(+), 2 deletions(-) create mode 100644 t/tests/cruft-gfdl-invariants/debian/src/oldfalsepositive/mailutils.texi diff --git a/checks/cruft.pm b/checks/cruft.pm index 12b2006..00ec871 100644 --- a/checks/cruft.pm +++ b/checks/cruft.pm @@ -500,8 +500,8 @@ sub find_cruft { # explicitly states it has no "bad sections". given($+{gfdlsections}) { when(m/no $s* Invariant $s+ Sections? $s* ,? - $s+ (?:with$s+)? (?:the$s+)? no $s+ Front(?:\\?-)?$s*Cover $s+ Texts? $s* ,? $s+ (?:and$s+)? - (?:with$s+)? (?:the$s+)? no $s+ Back(?:\\?-)?$s*Cover $s+ Texts?/xiso) { + $s+ (?:with$s+)? (?:the$s+)? no $s+ Front(?:\\?-)?$s*Cover $s+ (?:Texts?)? $s* ,? $s+ (?:and$s+)? + (?:with$s+)? (?:the$s+)? no $s+ Back(?:\\?-)?$s*Cover/xiso) { # no invariant } when(m/no $s+ Invariant $s+ Sections?,? diff --git a/t/tests/cruft-gfdl-invariants/debian/src/oldfalsepositive/mailutils.texi b/t/tests/cruft-gfdl-invariants/debian/src/oldfalsepositive/mailutils.texi new file mode 100644 index 0000000..dffaccc --- /dev/null +++ b/t/tests/cruft-gfdl-invariants/debian/src/oldfalsepositive/mailutils.texi @@ -0,0 +1,6 @@ +Permission is granted to copy, distribute and/or modify this document +under the terms of the GNU Free Documentation License, Version 1.2 or +any later version published by the Free Software Foundation; with no +Invariant Sections, no Front-Cover, and no Back-Cover texts. +A copy of the license is included in the section entitled ``GNU Free +Documentation License''. -- 1.7.10.4
From 35359ebb4e57e850a0bd0d6ceefff427e1ddd149 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Bastien=20ROUCARI=C3=88S?= <roucaries.bast...@gmail.com> Date: Sat, 15 Jun 2013 17:42:39 +0200 Subject: [PATCH 2/3] Fix a new gfdl false positive Fix a false positive in parsewiki --- checks/cruft.pm | 13 +++++++++++-- .../debian/src/oldfalsepositive/parsewiki.txt | 4 ++++ 2 files changed, 15 insertions(+), 2 deletions(-) create mode 100644 t/tests/cruft-gfdl-invariants/debian/src/oldfalsepositive/parsewiki.txt diff --git a/checks/cruft.pm b/checks/cruft.pm index 00ec871..7fc3c5a 100644 --- a/checks/cruft.pm +++ b/checks/cruft.pm @@ -484,7 +484,7 @@ sub find_cruft { my $s = qr{(?: \s | # regular space(s) \@c(?:omment)? | # Tex info comment - [%\*\"\|] | # String, C-style comment/javadoc indent, quotes for strings, pipe in some txt + [%\*\"\|\\] | # String, C-style comment/javadoc indent, quotes for strings, pipe and antislash in some txt \"\s*, | # String array (e.g. "line1",\n"line2") ,\s*\" | # String array (e.g. "line1"\n ,"line2"), seen in findutils \\n | # Verbatim \n in string array @@ -493,7 +493,7 @@ sub find_cruft { <br\s*/?> | # (X)HTML line breaks </?link.*?> | # xml link </?a.*?> | # a link - </?p.*?> | # html link + </?p.*?> | # html paragraph \(\*note.*?::\) | # info file note )}xsmo; # GFDL license, assume it is bad unless it @@ -518,6 +518,15 @@ sub find_cruft { /xismo) { # no invariant libnss-pgsql version } + when(m/\A $s* (?: [\,\.;] $s* )? version $s+ \d+(?:\.\d+)? $s+ + (?:or $s+ any $s+ later $s+ version $s+)? + published $s+ by $s+ the $s+ Free $s+ Software $s+ Foundation $s* + (?: [,\.;] $s*)? + without $s+ any $s+ Invariant $s+ Sections $s* + (?: [,\.;] $s*)? \Z + /xismo) { + # no invariant parsewiki version + } when(m/(?: [,\.;] $s*)? version $s+ \d+(?:\.\d+)? $s+ (?:or $s+ any $s+ later $s+ version $s+)? published $s+ by $s+ the $s+ Free $s+ Software $s+ Foundation $s* diff --git a/t/tests/cruft-gfdl-invariants/debian/src/oldfalsepositive/parsewiki.txt b/t/tests/cruft-gfdl-invariants/debian/src/oldfalsepositive/parsewiki.txt new file mode 100644 index 0000000..950d936 --- /dev/null +++ b/t/tests/cruft-gfdl-invariants/debian/src/oldfalsepositive/parsewiki.txt @@ -0,0 +1,4 @@ +Permission is granted to copy, distribute and/or modify this document under \ +the terms of the GNU Free Documentation License, Version 1.1 or any later \ +version published by the Free Software Foundation; without any Invariant \ +Sections. A copy of the license is included in the file GFDL. -- 1.7.10.4
From 8941623c83bacf3c0d1064a0f3dc23bd8255fdf9 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Bastien=20ROUCARI=C3=88S?= <roucaries.bast...@gmail.com> Date: Sat, 15 Jun 2013 18:01:29 +0200 Subject: [PATCH 3/3] Be not greedy for checking gfdl invariants Fix a lot of invariants problem for instance in shorewall-doc --- checks/cruft.pm | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/checks/cruft.pm b/checks/cruft.pm index 7fc3c5a..46064e6 100644 --- a/checks/cruft.pm +++ b/checks/cruft.pm @@ -477,7 +477,7 @@ sub find_cruft { # # See cruft-gfdl-fp-sliding-win for the test case when(index($_, 'license') > -1 && m/gnu (?:\s+|\s*<\/span>\s*|\s*\}\s+)? free \s+ - documentation \s+ license (?'gfdlsections'.{0,1024}) + documentation \s+ license (?'gfdlsections'.{0,1024}?) a \s+ copy \s+ of \s+ the \s+ license \s+ is \s+ included/xsm) { if (!exists $licenseproblemhash{'gfdl-invariants'}) { # local space -- 1.7.10.4