This is the mail archive of the
cygwin-patches
mailing list for the Cygwin project.
Re: [PATCH] Fix for sending SIGHUP when the pty master side isclose()-ed
On Wed, 17 Aug 2005, Christopher Faylor wrote:
> On Wed, Aug 17, 2005 at 06:30:25PM +0300, Pavel Tsekov wrote:
> >The attached patch solves this problem by rearranging the code a bit. It
> >tries to be non-intrusive. I offer it for discussion and comments. I hope
> >that my description of the problem and the patch will help to resolve the
> >issue even if the patch will get rejected in favour of a better one.
>
> It seems like your description and your rearrangement are probably
> correct. This is a classic race.
>
> Want to provide a changelog?
Here it is - I didn't expect such a fast response :)
2005-08-17 Pavel Tsekov <ptsekov@gmx.net>
* fhandler_tty.cc (fhandler_tty_common::close): Rearrange the
code so that the master end of the input and output pipes is
closed before signalling an EOF event to the slave.
(fhandler_pty_master::close): Likewise.