summaryrefslogtreecommitdiff
path: root/lib/sqfs/read_super.c
diff options
context:
space:
mode:
authorDavid Oberhollenzer <david.oberhollenzer@sigma-star.at>2019-11-24 16:41:23 +0100
committerDavid Oberhollenzer <david.oberhollenzer@sigma-star.at>2019-11-24 16:47:49 +0100
commit3c79472a773210127bec1768aaf85e540daa3f9f (patch)
treea2c3802d5da25ded3eeb8274e68024d36485b662 /lib/sqfs/read_super.c
parent162142b7930248d83a77e8d8f4eba5896d5b267a (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/read_super.c')
-rw-r--r--lib/sqfs/read_super.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/lib/sqfs/read_super.c b/lib/sqfs/read_super.c
index 437ee07..f5cc988 100644
--- a/lib/sqfs/read_super.c
+++ b/lib/sqfs/read_super.c
@@ -54,7 +54,7 @@ int sqfs_super_read(sqfs_super_t *super, sqfs_file_t *file)
if ((temp.block_size - 1) & temp.block_size)
return SQFS_ERROR_SUPER_BLOCK_SIZE;
- if (temp.block_size < 4096 || temp.block_size >= (1 << 20))
+ if (temp.block_size < 4096 || temp.block_size > (1 << 20))
return SQFS_ERROR_SUPER_BLOCK_SIZE;
if (temp.block_log < 12 || temp.block_log > 20)