From 7ad5289d6661f9b31e820108f18f28b50586912c Mon Sep 17 00:00:00 2001 From: Stefan Rueger Date: Wed, 11 Jan 2023 23:50:26 +0000 Subject: [PATCH] Silence sign-compare warnings in dfu.c --- src/dfu.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/dfu.c b/src/dfu.c index a51c93db..f5343158 100644 --- a/src/dfu.c +++ b/src/dfu.c @@ -275,12 +275,12 @@ int dfu_getstatus(struct dfu_dev *dfu, struct dfu_status *status) return -1; } - if (result < sizeof(struct dfu_status)) { + if (result < (int) sizeof(struct dfu_status)) { pmsg_error("unable to get DFU status: %s\n", "short read"); return -1; } - if (result > sizeof(struct dfu_status)) { + if (result > (int) sizeof(struct dfu_status)) { pmsg_error("oversize read (should not happen); exiting\n"); exit(1); }