From 2647831aa62c4b0cef27cec0eec42c5fc3ef412b Mon Sep 17 00:00:00 2001 From: David Robillard Date: Wed, 11 Dec 2024 19:05:02 -0500 Subject: Fix widening conversion after arithmetic --- src/sratom.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/sratom.c b/src/sratom.c index b51be47..fe48750 100644 --- a/src/sratom.c +++ b/src/sratom.c @@ -327,7 +327,7 @@ sratom_write(Sratom* sratom, const size_t len = (size_t)size * 2U; char* const str = (char*)calloc(len + 1, 1); - for (uint32_t i = 0U; i < size; ++i) { + for (size_t i = 0U; i < size; ++i) { const uint8_t byte = ((const uint8_t*)body)[i]; str[2U * i] = hex_chars[byte >> 4U]; str[2U * i + 1U] = hex_chars[byte & 0x0FU]; -- cgit v1.2.1