summaryrefslogtreecommitdiffstats
path: root/patches/ipkg-utils-050831/0004-arfile_even_alignment.patch
blob: 1eda788ff043733687630fb02a180fdf829961d2 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
From: the openembedded project <http://openembedded.net/>
Date: Fri, 22 Jan 2010 11:05:12 +0100
Subject: [PATCH] arfile_even_alignment

---
 arfile.py | 2 ++
 1 file changed, 2 insertions(+)

diff --git a/arfile.py b/arfile.py
index 0bcd8d0..597cb3d 100644
--- a/arfile.py
+++ b/arfile.py
@@ -86,6 +86,8 @@ class ArFile:
                 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())