libuv/include/uv
Matheus Izvekov 51a22f60d6
unix,win: fix busy loop with zero timeout timers (#4250)
Calling `uv_timer_start(h, cb, 0, 0)` from a timer callback resulted in
the timer running immediately because it was inserted at the front of
the timer heap.

If the callback did that every time, libuv would effectively busy-loop
in `uv__run_timers()` and never make forward progress.

Work around that by collecting all expired timers into a queue and only
running their callback afterwards.

Fixes: https://github.com/libuv/libuv/issues/4245
Co-authored-by: Ben Noordhuis <info@bnoordhuis.nl>
2023-12-22 12:40:50 +01:00
..
aix.h core: move all include files except uv.h to uv/ 2018-06-14 18:39:32 +02:00
bsd.h core: move all include files except uv.h to uv/ 2018-06-14 18:39:32 +02:00
darwin.h unix,win: replace QUEUE with struct uv__queue (#4022) 2023-05-25 00:04:30 +02:00
errno.h include: add EUNATCH errno mapping (#4047) 2023-06-16 09:27:39 -04:00
linux.h unix,win: replace QUEUE with struct uv__queue (#4022) 2023-05-25 00:04:30 +02:00
os390.h core: move all include files except uv.h to uv/ 2018-06-14 18:39:32 +02:00
posix.h core: move all include files except uv.h to uv/ 2018-06-14 18:39:32 +02:00
sunos.h core: move all include files except uv.h to uv/ 2018-06-14 18:39:32 +02:00
threadpool.h unix,win: replace QUEUE with struct uv__queue (#4022) 2023-05-25 00:04:30 +02:00
tree.h chore: use for(;;) instead of while 2021-04-04 17:15:35 +02:00
unix.h unix,win: fix busy loop with zero timeout timers (#4250) 2023-12-22 12:40:50 +01:00
version.h Now working on version 1.47.1 2023-11-06 13:24:46 -05:00
win.h unix,win: fix busy loop with zero timeout timers (#4250) 2023-12-22 12:40:50 +01:00