tags 996995 + patch
severity 996995 serious
thanks

Patch attached.


Regards,

-- 
      ,''`.
     : :'  :     Chris Lamb
     `. `'`      la...@debian.org / chris-lamb.co.uk
       `-
diff --git a/dhpython/debhelper.py b/dhpython/debhelper.py
index 7308bbe..55b91c0 100644
--- a/dhpython/debhelper.py
+++ b/dhpython/debhelper.py
@@ -80,6 +80,10 @@ class DebHelper:
         except IOError:
             raise Exception('cannot find debian/control file')
 
+        # Strip any paragraphs that are entirely empty, which could be caused
+        # by commented-out packages.
+        paragraphs = [x for x in paragraphs if x]
+
         if len(paragraphs) < 2:
             raise Exception('Unable to parse debian/control, found less than '
                             '2 paragraphs')

Reply via email to