[PATCH] Cygwin: pty: Disable FreeConsole() on close for non cygwin process.
- After commit e1a0775dc0545b5f9c81b09a327fc110c538b7b4, the problem
reported in https://www.cygwin.com/ml/cygwin/2020-01/msg00093.html occurs. For Gnu scren and tmux, calling FreeConsole() on pty close
is necessary. However, if FreeConsole() is called, cygwin setup
with '-h' option does not work. Therefore, the commit
e1a0775dc0545b5f9c81b09a327fc110c538b7b4 delayed closing pty.
This is the cause of the problem above. Now, instead of delaying
pty close, FreeConsole() is not called if the process is non cygwin
processes such as cygwin setup.
winsup/cygwin/fhandler.h | 1 +
winsup/cygwin/fhandler_tty.cc | 13 +++++++++++--
winsup/cygwin/spawn.cc | 6 ++++--
3 files changed, 16 insertions(+), 4 deletions(-)