[Reportbug-maint] Bug#857013: reportbug: Attaching patch

Michal Suchanek hramrach at gmail.com
Thu Apr 13 08:52:02 UTC 2017


Package: reportbug
Version: 7.1.5
Followup-For: Bug #857013

Fix:


--- /usr/lib/python3/dist-packages/reportbug/utils.py	2017-04-13 10:49:24.126454516 +0200
+++ /usr/lib/python3/dist-packages/reportbug/utils.py~	2017-04-13 10:49:17.663966502 +0200
@@ -369,9 +369,7 @@
                 confmode = False
             else:
                 # re is used to identify also conffiles with spaces in the name
-                tmp = re.findall(r' (.+) ([0-9a-f]+).*$', line)
-                if len(tmp) > 0:
-                    conffiles = conffiles + [tmp[0]]
+                conffiles = conffiles + [re.findall(r' (.+) ([0-9a-f]+).*$', line)[0]]
 
         if versionre.match(line):
             (crud, pkgversion) = line.split(": ", 1)

Versions of packages reportbug depends on:
ii  apt                1.4
ii  python3-reportbug  7.1.5
pn  python3:any        <none>
-------------- next part --------------
--- /usr/lib/python3/dist-packages/reportbug/utils.py	2017-04-13 10:49:24.126454516 +0200
+++ /usr/lib/python3/dist-packages/reportbug/utils.py~	2017-04-13 10:49:17.663966502 +0200
@@ -369,9 +369,7 @@
                 confmode = False
             else:
                 # re is used to identify also conffiles with spaces in the name
-                tmp = re.findall(r' (.+) ([0-9a-f]+).*$', line)
-                if len(tmp) > 0:
-                    conffiles = conffiles + [tmp[0]]
+                conffiles = conffiles + [re.findall(r' (.+) ([0-9a-f]+).*$', line)[0]]
 
         if versionre.match(line):
             (crud, pkgversion) = line.split(": ", 1)


More information about the Reportbug-maint mailing list