program will hang when dup and close fd opend by posix_openpt

Takashi Yano takashi.yano@nifty.ne.jp
Thu Jan 14 09:34:40 GMT 2021


On Thu, 14 Jan 2021 13:48:25 +0800
Peiyuan Song via Cygwin-developers <cygwin-developers@cygwin.com> wrote:
> dup will clone all info from `fhandler_pty_master` except pty master
> control thread and pty master forwarding thread, when close that fd
> the `fhandler_pty_master` heap will be reclaimed, but  the thread run
> on  `fhandler_pty_master` object will not stop. when close duped fd,
> those threads will access the reclaimed space and cause this issue.

Thanks for the report. Let me consider.

-- 
Takashi Yano <takashi.yano@nifty.ne.jp>


More information about the Cygwin-developers mailing list