[elbe-devel] [PATCH v2 6/6] pkgutils: Circumvent error

bage at linutronix.de bage at linutronix.de
Mon Sep 2 12:46:53 CEST 2019


From: Bastian Germann <bage at linutronix.de>

Parsing a whole dsc throws an apt error: "Unable to parse package file."
As this is only for sections after Files section, get rid of it by stopping
the parser.

Signed-off-by: Bastian Germann <bage at linutronix.de>
Reviewed-by: Torben Hohn <torben.hohn at linutronix.de>
---
 elbepack/pkgutils.py | 1 +
 1 file changed, 1 insertion(+)

diff --git a/elbepack/pkgutils.py b/elbepack/pkgutils.py
index 155cc050..31a5c068 100644
--- a/elbepack/pkgutils.py
+++ b/elbepack/pkgutils.py
@@ -68,6 +68,7 @@ def get_dsc_size(fname):
             files = [f.strip().split(' ') for f in files]
             for f in files:
                 sz += int(f[1])
+            break
 
     return sz
 
-- 
2.20.1




More information about the elbe-devel mailing list