On 2026-04-04 13:02, Bruno Haible wrote:
Paul Eggert wrote:
In this patch I did not add a FIXME for sigpipe-die; instead, I added a
comment saying that install_sigpipe_die_handler should be called only in
a single-threaded process
Actually, the restriction can be relaxed: It is OK to call
install_sigpipe_die_handler in a multithreaded program, at a moment
when the main thread is still the only thread.
Doesn't that tighten the restriction rather than relax it? The function
is safe whenever a process is single-threaded, regardless of whether the
process was formerly multithreaded. And (though this is pretty obscure)
the function need not be called from the main thread.