diff options
author | David Oberhollenzer <david.oberhollenzer@sigma-star.at> | 2019-11-24 16:41:23 +0100 |
---|---|---|
committer | David Oberhollenzer <david.oberhollenzer@sigma-star.at> | 2019-11-24 16:47:49 +0100 |
commit | 3c79472a773210127bec1768aaf85e540daa3f9f (patch) | |
tree | a2c3802d5da25ded3eeb8274e68024d36485b662 /lib/sqfs/super.c | |
parent | 162142b7930248d83a77e8d8f4eba5896d5b267a (diff) |
Fix check of block size in super block
The check needs to include 1M, which is still a valid block size.
Signed-off-by: David Oberhollenzer <david.oberhollenzer@sigma-star.at>
Diffstat (limited to 'lib/sqfs/super.c')
-rw-r--r-- | lib/sqfs/super.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/lib/sqfs/super.c b/lib/sqfs/super.c index 20ce420..4ed95ae 100644 --- a/lib/sqfs/super.c +++ b/lib/sqfs/super.c @@ -20,7 +20,7 @@ int sqfs_super_init(sqfs_super_t *super, size_t block_size, sqfs_u32 mtime, if (block_size & (block_size - 1)) return SQFS_ERROR_SUPER_BLOCK_SIZE; - if (block_size < 4096 || block_size >= (1 << 20)) + if (block_size < 4096 || block_size > (1 << 20)) return SQFS_ERROR_SUPER_BLOCK_SIZE; memset(super, 0, sizeof(*super)); |