File tree Expand file tree Collapse file tree 2 files changed +3
-3
lines changed
Expand file tree Collapse file tree 2 files changed +3
-3
lines changed Original file line number Diff line number Diff line change 22
33from setuptools import setup , find_packages
44
5- version = '0.7.2 '
5+ version = '0.8.0 '
66
77setup (
88 name = 'ubi_reader' ,
Original file line number Diff line number Diff line change @@ -166,13 +166,13 @@ def _write_reg_file(path, data):
166166def _process_reg_file (ubifs , inode , path ):
167167 try :
168168 buf = bytearray ()
169+ start_key = 0x00 | (UBIFS_DATA_KEY << UBIFS_S_KEY_BLOCK_BITS )
169170 if 'data' in inode :
170171 compr_type = 0
171172 sorted_data = sorted (inode ['data' ], key = lambda x : x .key ['khash' ])
172- last_khash = sorted_data [ 0 ]. key [ 'khash' ] - 1
173+ last_khash = start_key - 1
173174
174175 for data in sorted_data :
175-
176176 # If data nodes are missing in sequence, fill in blanks
177177 # with \x00 * UBIFS_BLOCK_SIZE
178178 if data .key ['khash' ] - last_khash != 1 :
You can’t perform that action at this time.
0 commit comments