diff options
author | David Oberhollenzer <david.oberhollenzer@sigma-star.at> | 2020-02-23 03:44:33 +0100 |
---|---|---|
committer | David Oberhollenzer <david.oberhollenzer@sigma-star.at> | 2020-02-23 04:02:49 +0100 |
commit | c924d87a4cbbeb93825f34f997add1ca4573a368 (patch) | |
tree | a2497b2954e0f6538cfa669062ab409f16518fc7 /lib/common/data_reader_dump.c | |
parent | 7350bebc4ceee0bf065e73f392edb725f8d0cd14 (diff) |
Unify the payload counters in the sqfs_inode_generic_t
Instead of having seperate counters for blocks, dir index bytes
and having to fiddle out the link target size, simply use a single
value that stores the number of payload bytes used.
A seperate "payload bytes available" is used for dynamically
growing inodes during processing.
Signed-off-by: David Oberhollenzer <david.oberhollenzer@sigma-star.at>
Diffstat (limited to 'lib/common/data_reader_dump.c')
-rw-r--r-- | lib/common/data_reader_dump.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/lib/common/data_reader_dump.c b/lib/common/data_reader_dump.c index 33bfc4f..d832388 100644 --- a/lib/common/data_reader_dump.c +++ b/lib/common/data_reader_dump.c @@ -57,7 +57,7 @@ int sqfs_data_reader_dump(const char *name, sqfs_data_reader_t *data, allow_sparse = false; #endif - for (i = 0; i < inode->num_file_blocks; ++i) { + for (i = 0; i < sqfs_inode_get_file_block_count(inode); ++i) { diff = (filesz < block_size) ? filesz : block_size; if (SQFS_IS_SPARSE_BLOCK(inode->extra[i]) && allow_sparse) { |