commit | d3a61059c04bd82329707324fac0d48e191edbf4 | [log] [tgz] |
---|---|---|
author | Alexey Izbyshev <izbyshev@ispras.ru> | Thu Feb 29 14:13:18 2024 +0300 |
committer | Rich Felker <dalias@aerifal.cx> | Thu Feb 29 10:07:03 2024 -0500 |
tree | 4289e49a5272bbd4367f5d2d42a5383dcdb609de | |
parent | 80e3b09823a1d718664bc13704f3f7c19038a19e [diff] |
posix_spawn: fix child spinning on write to a broken pipe A child process created by posix_spawn reports errors to its parent via a pipe, retrying infinitely on any write error to prevent falsely reporting success. If the (original) parent dies before write is attempted, there is nobody to report to, but the child will remain stuck in the write loop forever if SIGPIPE is blocked or ignored. Fix this by not retrying write if it fails with EPIPE.