reftable/stack: stop using `sleep_millisec()`

Refactor our use of `sleep_millisec()` by open-coding it with poll(3p), which is the current implementation of this function. Ideally, we'd use a more direct way to sleep, but there is no equivalent to sleep(3p) that would accept milliseconds as input. Signed-off-by: Patrick Steinhardt <ps@pks.im> Signed-off-by: Junio C Hamano <gitster@pobox.com>

Patrick Steinhardt committed Feb 18, 2025 at 10:20 UTC 10f2935c7f2070368dadde582f94c9c76e2fe991
1 file changed +1 -1
reftable/stack.c
+1 -1
@@ -524,7 +524,7 @@ static int reftable_stack_reload_maybe_reuse(struct reftable_stack *st,
524 fd = -1;
525
526 delay = delay + (delay * reftable_rand()) / UINT32_MAX + 1;
527 - sleep_millisec(delay);
527 + poll(NULL, 0, delay);
528 }
529
530 out: