From 6d5e7c9b608130088c2335d2fdc6cf4b04a0253f Mon Sep 17 00:00:00 2001 From: Andy Wingo Date: Thu, 22 May 2025 16:15:31 +0200 Subject: [PATCH] Fix bof returning blocks from the evacuation target list to empties --- src/nofl-space.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/nofl-space.h b/src/nofl-space.h index b36694d82..570884d72 100644 --- a/src/nofl-space.h +++ b/src/nofl-space.h @@ -1840,7 +1840,7 @@ nofl_space_shrink(struct nofl_space *space, size_t bytes) { size_t active = nofl_active_block_count(space); size_t target = space->evacuation_minimum_reserve * active; ssize_t avail = nofl_block_count(&space->evacuation_targets); - while (avail > target && pending > 0) { + while (avail-- > target && pending > 0) { struct nofl_block_ref block = nofl_block_list_pop(&space->evacuation_targets); GC_ASSERT(!nofl_block_is_null(block));