ipkg-utils: fix ipk (ar) file processing to handle odd-length data blocks.
authorMike Westerhof <mwester@dls.net>
Tue, 17 Jun 2008 03:50:03 +0000 (03:50 +0000)
committerMike Westerhof <mwester@dls.net>
Tue, 17 Jun 2008 03:50:03 +0000 (03:50 +0000)
Closes bug #4350.

packages/ipkg-utils/ipkg-utils/arfile_even_alignment.patch [new file with mode: 0644]
packages/ipkg-utils/ipkg-utils_1.6+cvs20050404.bb

diff --git a/packages/ipkg-utils/ipkg-utils/arfile_even_alignment.patch b/packages/ipkg-utils/ipkg-utils/arfile_even_alignment.patch
new file mode 100644 (file)
index 0000000..3ab133f
--- /dev/null
@@ -0,0 +1,11 @@
+--- ipkg-utils/arfile.py.orig  2008-06-11 21:07:01.000000000 -0500
++++ ipkg-utils/arfile.py       2008-06-14 19:56:04.000000000 -0500
+@@ -86,6 +86,8 @@
+                 return FileSection(self.f, self.f.tell(), size)
+             # Skip data and loop
++            if size % 2:
++                size = size + 1
+             data = self.f.seek(size, 1)
+ #            print hex(f.tell())
index f64e644..707a005 100644 (file)
@@ -5,12 +5,13 @@ LICENSE = "GPL"
 CONFLICTS = "ipkg-link"
 RDEPENDS = "python"
 SRCDATE = "20050404"
-PR = "r20"
+PR = "r20.1"
 
 SRC_URI = "${HANDHELDS_CVS};module=ipkg-utils \
            file://ipkg-utils-fix.patch;patch=1 \
            file://ipkg-py-sane-vercompare.patch;patch=1 \
            file://ipkg-py-tarfile.patch;patch=1 \
+           file://arfile_even_alignment.patch;patch=1 \
            file://ipkg-make-index-track-stamps.patch;patch=1 \
            file://fields_tweaks.patch;patch=1 "