git: cba2fa7c5b5a - main - makefs: Add a cast to placate static analyzers

From: Mark Johnston <markj_at_FreeBSD.org>
Date: Tue, 04 Oct 2022 17:06:18 UTC
The branch main has been updated by markj:

URL: https://cgit.FreeBSD.org/src/commit/?id=cba2fa7c5b5ac5738907cc1603cef2666d5b109d

commit cba2fa7c5b5ac5738907cc1603cef2666d5b109d
Author:     Mark Johnston <markj@FreeBSD.org>
AuthorDate: 2022-10-04 16:50:13 +0000
Commit:     Mark Johnston <markj@FreeBSD.org>
CommitDate: 2022-10-04 17:05:54 +0000

    makefs: Add a cast to placate static analyzers
    
    "prefixlen" will always be smaller than 32 but adding a cast is
    harmless.
    
    Reported by:    Coverity
---
 usr.sbin/makefs/zfs/zap.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/usr.sbin/makefs/zfs/zap.c b/usr.sbin/makefs/zfs/zap.c
index 0bcc77d1aca0..12183158c675 100644
--- a/usr.sbin/makefs/zfs/zap.c
+++ b/usr.sbin/makefs/zfs/zap.c
@@ -387,7 +387,7 @@ zap_fat_write(zfs_opt_t *zfs, zfs_zap_t *zap)
 	 * header.
 	 */
 	prefixlen = zap_fat_write_prefixlen(zap, &l);
-	lblkcnt = 1 << prefixlen;
+	lblkcnt = (uint64_t)1 << prefixlen;
 	leafblks = ecalloc(lblkcnt, blksz);
 	for (unsigned int li = 0; li < lblkcnt; li++) {
 		l.l_phys = (zap_leaf_phys_t *)(leafblks + li * blksz);