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

[SCM] Debian package checker branch, master, updated. 2.5.12-94-gf9f1b3e



The following commit has been merged in the master branch:
commit 98a69f9da965cd904802fd6eb1d3d56d736491c1
Author: Bastien ROUCARIÈS <roucaries.bastien@gmail.com>
Date:   Sun May 19 11:49:32 2013 +0200

    Fix a false positive for the gfdl check in case of GNU with under <span> tags
    
    diveintopython trigger false positive due to convoluted license. The solution is better matching
    of the license by allowing some HTML tags durings scanning of license text.
    
    Signed-off-by: Niels Thykier <niels@thykier.net>

diff --git a/checks/cruft b/checks/cruft
index ef38b5a..da0d39c 100644
--- a/checks/cruft
+++ b/checks/cruft
@@ -480,7 +480,7 @@ sub find_cruft {
                 # if the "redeeming" part is in the next block.
                 #
                 # See cruft-gfdl-fp-sliding-win for the test case
-                when(m/GNU \s+ Free \s+ Documentation \s+ License (?'gfdlsections'.{0,1024})
+                when(m/GNU (?:\s+|\s*<\/span>\s*)? Free \s+ Documentation \s+ License (?'gfdlsections'.{0,1024})
                          A \s+ copy \s+ of \s+ the \s+ license \s+ is \s+ included/xis) {
                     if (!exists $licenseproblemhash{'gfdl-invariants'}) {
                         # local space
diff --git a/t/tests/cruft-gfdl-invariants/debian/src/diveintopythonok.html b/t/tests/cruft-gfdl-invariants/debian/src/diveintopythonok.html
new file mode 100644
index 0000000..6ace5df
--- /dev/null
+++ b/t/tests/cruft-gfdl-invariants/debian/src/diveintopythonok.html
@@ -0,0 +1,12 @@
+<html>
+<!--- This is a old false positive -->
+<body>
+                  <div class="legalnotice">
+                     <p>Permission is granted to copy, distribute, and/or modify this document under the terms of the <span class="acronym">GNU</span> Free Documentation License, Version 1.1 or any later version published by the Free Software Foundation; with no Invariant
+                        Sections, no Front-Cover Texts, and no Back-Cover Texts.  A copy of the license is included in <a href="../appendix/fdl.html" title="Appendix&nbsp;G.&nbsp;GNU Free Documentation License">Appendix&nbsp;G, <i>GNU Free Documentation License</i></a>.
+                     </p>
+                     <p>The example programs in this book are free software; you can redistribute and/or modify them under the terms of the <span class="application">Python</span> license as published by the <span class="application">Python</span> Software Foundation. A copy of the license is included in <a href="../appendix/license.html" title="Appendix&nbsp;H.&nbsp;Python license">Appendix&nbsp;H, <i>Python license</i></a>.
+                     </p>
+                  </div>
+</body>
+</html>

-- 
Debian package checker


Reply to: