On Tue, Aug 30, 2022 at 11:00:03AM +0000, Laurent Bercot wrote: > >The write end of the pipe is closed when envs are written, therefore it > >make sense to close read end as well after envs are read. This prevents > >fd leaking to the app. > > Good catch, thanks. Applied with a little modification: since close() > can set errno, it shouldn't be called between read() and > strerr_diefu1sys() (which reads errno).
Ah, I see, thanks! > Not going to cut a release just for this, because the bug is minor > (the leaked fd is completely unusable). Makes sense, no problem at all. Petr