From 440a2066e4f35f64623a09a3253a4aac8f48279c Mon Sep 17 00:00:00 2001 From: Sebastian Reimers Date: Wed, 8 Jan 2025 09:36:07 +0100 Subject: [PATCH] fix size_t win 32-bit warning --- src/mem/mem_pool.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/mem/mem_pool.c b/src/mem/mem_pool.c index 3ac6a61bf..10f20e61a 100644 --- a/src/mem/mem_pool.c +++ b/src/mem/mem_pool.c @@ -165,8 +165,8 @@ struct mem_pool_entry *mem_pool_borrow(struct mem_pool *pool) if (!pool) return NULL; - for (size_t i = re_atomic_acq(&pool->next_free); i < pool->nmemb; - i++) { + for (size_t i = (size_t)re_atomic_acq(&pool->next_free); + i < pool->nmemb; i++) { if (!re_atomic_acq(&pool->objs[i].used)) { re_atomic_rls_set(&pool->objs[i].used, true); re_atomic_rls_set(&pool->next_free, i + 1);