]> git.ipfire.org Git - thirdparty/util-linux.git/commitdiff
libblkid: (bcachefs) fix compiler warning [-Werror=sign-compare]
authorKarel Zak <kzak@redhat.com>
Wed, 23 Aug 2023 09:53:45 +0000 (11:53 +0200)
committerThomas Weißschuh <thomas@t-8ch.de>
Fri, 22 Sep 2023 18:47:12 +0000 (20:47 +0200)
Addresses: https://github.com/util-linux/util-linux/pull/2427
Signed-off-by: Karel Zak <kzak@redhat.com>
(cherry picked from commit 17873d38fc97913c0a31d4bd08cfbfe45c4de5be)

libblkid/src/superblocks/bcache.c

index 2368770427ead4b822e8504c4576e2ef7e844b8c..6ab3fe9d4cce44bc2aead21f7d9cfc6bb8de4041 100644 (file)
@@ -311,7 +311,7 @@ static int probe_bcachefs(blkid_probe pr, const struct blkid_idmag *mag)
                return BLKID_PROBE_NONE;
 
        sb_size = BCACHEFS_SB_FIELDS_OFF + BYTES(bcs);
-       if (sb_size > BCACHEFS_SECTOR_SIZE << bcs->layout.sb_max_size_bits)
+       if (sb_size > ((uint64_t) BCACHEFS_SECTOR_SIZE << bcs->layout.sb_max_size_bits))
                return BLKID_PROBE_NONE;
 
        if (sb_size > BCACHEFS_SB_MAX_SIZE)