From 757b34a754e36606c05ae41f61018b106325acae Mon Sep 17 00:00:00 2001 From: Eugene Syromiatnikov Date: Mon, 26 Jul 2021 19:55:41 +0200 Subject: [PATCH] gen_updates2.py: consistently specify endianness in struct.unpack formats * gen_updates2.py (read_revs_dir): Consistently prefix struct.unpack formats with "<" to signify that it is little-endian data. Resolves: #1880064 Signed-off-by: Eugene Syromiatnikov --- gen_updates2.py | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/gen_updates2.py b/gen_updates2.py index 51056f9..e0bb6c6 100755 --- a/gen_updates2.py +++ b/gen_updates2.py @@ -144,7 +144,7 @@ def read_revs_dir(path, args, src=None, ret=None): offs = 0 while offs < sz: f.seek(offs, os.SEEK_SET) - hdr = struct.unpack("IiIIIIIIIIII", f.read(48)) + hdr = struct.unpack(" 48: f.seek(hdr[7], os.SEEK_CUR) - ext_tbl = struct.unpack("IIIII", f.read(20)) + ext_tbl = struct.unpack("