* fhandler_tty.cc (fhandler_tty_slave::init): Add debugging. Use tcsetpgrp to
potentially set pgid since it is smarter about deciding if a process is in the background. * include/sys/cygwin.h (PID_ORPHANED): Actually delete as planned. (PID_NOTCYGWIN): Correctly define.
This commit is contained in:
@ -723,7 +723,11 @@ fhandler_tty_slave::init (HANDLE f, DWORD a, mode_t)
|
||||
tty is a non-cygwin process or we've been started directly
|
||||
from a non-Cygwin process with no Cygwin ancestry. */
|
||||
if (!p || ISSTATE (p, PID_NOTCYGWIN))
|
||||
tc->setpgid (myself->pgid);
|
||||
{
|
||||
termios_printf ("Setting process group leader to %d since %W(%d) is not a cygwin process",
|
||||
myself->pgid, p->progname, p->pid);
|
||||
tcsetpgrp (myself->pgid);
|
||||
}
|
||||
}
|
||||
|
||||
if (f != INVALID_HANDLE_VALUE)
|
||||
|
Reference in New Issue
Block a user