Mail Archives: cygwin-developers/1998/02/02/06:57:03
Hi!
Thu Jan 22 18:46:40 1998 Ian Lance Taylor <ian AT cygnus DOT com>
* tty.h (class tty): Change slave_handles to int.
* tty.cc (fhandler_tty_slave::open): Check for invalid tty
handles. If this is the first slave, set slave_handles to 2;
otherwise, increment slave_handles.
(fhandler_tty_slave::close): Only close the tty handles if the
slave_handles field drops to 1.
This changes fools rxvt. Rxvt does the following:
pty = open("/dev/ptmx");
slave = ptsname(pty);
lstat(slave);
tty = open(slave);
Lstat call implemented in cygwin as fd=open(name); fstat(fd); close(fd).
This close call closes input_handle and output_handle in tty structure
(because number of slaves drops to 1) and tty=open(slave) call fails. Ian,
any ideas to fix it?
--
Sergey Okhapkin, http://www.lexa.ru/sos
Moscow, Russia
Looking for a job.
- Raw text -