summaryrefslogtreecommitdiff
path: root/libblkid
diff options
context:
space:
mode:
authorKarel Zak <kzak@redhat.com>2023-01-23 14:11:56 +0100
committerKarel Zak <kzak@redhat.com>2023-01-23 14:11:56 +0100
commit2ea397239683270a0fc8cd3b72ed5457f52dbda8 (patch)
tree01c8d15ebb92c653f48df8ffb28bca2e47183ab3 /libblkid
parenteef48b8c43c0f0d332b87956beb17a47ee1c3a6d (diff)
parent0ec43c07e0d70cb83e734d31e15f58fefe2347a2 (diff)
downloadutil-linux-2ea397239683270a0fc8cd3b72ed5457f52dbda8.tar.gz
Merge branch 'fix-befs' of https://github.com/mbroz/util-linux
* 'fix-befs' of https://github.com/mbroz/util-linux: libblkid: befs - avoid undefined shift
Diffstat (limited to 'libblkid')
-rw-r--r--libblkid/src/superblocks/befs.c3
1 files changed, 3 insertions, 0 deletions
diff --git a/libblkid/src/superblocks/befs.c b/libblkid/src/superblocks/befs.c
index 8de697ddc..5112d44f4 100644
--- a/libblkid/src/superblocks/befs.c
+++ b/libblkid/src/superblocks/befs.c
@@ -502,6 +502,9 @@ static int probe_befs(blkid_probe pr, const struct blkid_idmag *mag)
block_size != 1U << block_shift)
return BLKID_PROBE_NONE;
+ if (FS32_TO_CPU(bs->ag_shift, fs_le) > 64)
+ return BLKID_PROBE_NONE;
+
ret = get_uuid(pr, bs, &volume_id, fs_le);
if (ret != 0)