From 573fdf0b22e1a04f35909186d62eebc5da53b74e Mon Sep 17 00:00:00 2001 From: Leah Rowe Date: Sat, 14 Mar 2026 17:58:06 +0000 Subject: util/nvmutil: fix cast check Signed-off-by: Leah Rowe --- util/nvmutil/nvmutil.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'util') diff --git a/util/nvmutil/nvmutil.c b/util/nvmutil/nvmutil.c index c05487cf..c09ecd85 100644 --- a/util/nvmutil/nvmutil.c +++ b/util/nvmutil/nvmutil.c @@ -1850,7 +1850,7 @@ rw_file_exact(int fd, u8 *mem, size_t nrw, } /* Prevent theoretical overflow */ - if (rv > nrw - rc) + if ((size_t)rv > nrw - rc) goto err_rw_file_exact; rc += (size_t)rv; -- cgit v1.2.1