mirror of
https://github.com/kovidgoyal/calibre.git
synced 2025-07-08 10:44:09 -04:00
py3 compat
This commit is contained in:
parent
7514b58066
commit
568e9851a4
@ -48,7 +48,7 @@ class LRFDocument(LRFMetaFile):
|
||||
self.objects = {}
|
||||
self._file.seek(self.object_index_offset)
|
||||
obj_array = array.array("I", self._file.read(4*4*self.number_of_objects))
|
||||
if ord(array.array("i",[1]).tostring()[0:1])==0: # big-endian
|
||||
if ord(array.array("i",[1]).tobytes()[0:1])==0: # big-endian
|
||||
obj_array.byteswap()
|
||||
for i in range(self.number_of_objects):
|
||||
if not self.keep_parsing:
|
||||
|
Loading…
x
Reference in New Issue
Block a user