]> git.ipfire.org Git - thirdparty/openembedded/openembedded-core-contrib.git/commitdiff
fetch2: fix unpacking of deb packages
authorStephano Cetola <stephano.cetola@linux.intel.com>
Fri, 10 Jun 2016 17:56:38 +0000 (10:56 -0700)
committerRichard Purdie <richard.purdie@linuxfoundation.org>
Thu, 16 Jun 2016 16:37:52 +0000 (17:37 +0100)
Python 3 changed the return value of check_output to binary rather than
a string. This fix decodes the binary before calling splitlines, which
requires a string.

Signed-off-by: Stephano Cetola <stephano.cetola@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
lib/bb/fetch2/__init__.py

index f612318cc57b20aabe33be666a04dc28ad6fb81b..a63498a88bbe60ab44646e902a825fa4740a754b 100644 (file)
@@ -1395,7 +1395,7 @@ class FetchMethod(object):
                 output = subprocess.check_output('ar -t %s' % file, preexec_fn=subprocess_setup, shell=True)
                 datafile = None
                 if output:
-                    for line in output.splitlines():
+                    for line in output.decode().splitlines():
                         if line.startswith('data.tar.'):
                             datafile = line
                             break