From 961f4a1f29787cbb6bd9a8a43b6ac4f3f0d024c0 Mon Sep 17 00:00:00 2001 From: Nico Huber Date: Fri, 4 Oct 2019 17:34:22 +0200 Subject: Fix more sign-compare issues The one in the `dummyflasher` is a little peculiar. We actually never knew the type of the `st_size` field in `struct stat`. It happens to be `signed` in some systems (e.g. DJGPP). Change-Id: If36ba22606021400b385ea6083eacc7b360c20c5 Signed-off-by: Nico Huber Reviewed-on: https://review.coreboot.org/c/flashrom/+/35800 Tested-by: build bot (Jenkins) Reviewed-by: Jacob Garber Reviewed-by: Patrick Georgi --- libflashrom.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'libflashrom.c') diff --git a/libflashrom.c b/libflashrom.c index dbc5129c..1d8a9ae7 100644 --- a/libflashrom.c +++ b/libflashrom.c @@ -139,7 +139,7 @@ const char **flashrom_supported_programmers(void) */ struct flashrom_flashchip_info *flashrom_supported_flash_chips(void) { - int i = 0; + unsigned int i = 0; struct flashrom_flashchip_info *supported_flashchips = malloc(flashchips_size * sizeof(*supported_flashchips)); -- cgit v1.2.3