On Tue Jul 7, 2026 at 12:12 AM CEST, Heikki Linnakangas wrote:
> This relies on the signal to interrupt select(), but I'm afraid that's
> not guaranteed on all platforms. Also, there's a race condition if the
> signal arrives *just* before you call select(). That's what the
> "self-pipe hack" is for, see comments at waiteventset.c.
Ugh yes you're right. The comment above that block told me otherwise and
I didn't question it. Attached is a new version that improves the
comment and starts using the same 1 second poll on all platforms.