This is the mail archive of the cygwin mailing list for the Cygwin project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: Problem with pty allocation code, race condition?


On Mon, 17 May 2004, Christopher Faylor wrote:

> On Mon, May 17, 2004 at 09:29:44AM -0400, John P. Rouillard wrote:
> >Does the last cygwin snapshot contain any code changes in the pty
> >allocation area?
>
> Yes, the very latest snapshot attempts to fix this problem.  Please give
> it a try and report the results here.

I'm sorry to report that the problem I described in
<http://cygwin.com/ml/cygwin/2004-05/msg00596.html> (multiple xterms
started in quick succession get the same PTY) still exists in the 20040519
snapshot.  The output of "ps" after reproducing it with 4 xterms is below,
if it's of any help (the last bash, PID 1948, is a console).

$ ps
      PID    PPID    PGID     WINPID  TTY  UID    STIME COMMAND
     1732       1    1732       1748  con 1001 17:52:43 /usr/bin/xterm
     2812       1    2812       1268  con 1001 17:52:43 /usr/bin/xterm
     1160       1    1160       1152  con 1001 17:52:43 /usr/bin/xterm
     1772       1    1772       1844  con 1001 17:52:43 /usr/bin/xterm
S    1996    1732    1996       2036    0 1001 17:52:53 /usr/bin/bash
S    1244    2812    1244       2120    0 1001 17:52:53 /usr/bin/bash
I    1972    1160    1972       2132    0 1001 17:52:53 /usr/bin/bash
S    1988    1772    1988       2128    0 1001 17:52:53 /usr/bin/bash
     1948       1    1948       1948  con 1001 17:53:16 /usr/bin/bash
     2088    1948    2088        968  con 1001 17:53:19 /usr/bin/ps

Note that now it's the third xterm that got a working bash, so I think my
prior conclusion that the last one always wins was wrong.  Note also that,
for some reason, there was a 10-second delay between starting the xterms
and having the bash shells started.  As before, any ideas on how to debug
this are appreciated.  FWIW, cygcheck output is attached.
	Igor
-- 
				http://cs.nyu.edu/~pechtcha/
      |\      _,,,---,,_		pechtcha@cs.nyu.edu
ZZZzz /,`.-'`'    -.  ;-;;,_		igor@watson.ibm.com
     |,4-  ) )-,_. ,\ (  `'-'		Igor Pechtchanski, Ph.D.
    '---''(_/--'  `-'\_) fL	a.k.a JaguaR-R-R-r-r-r-.-.-.  Meow!

"I have since come to realize that being between your mentor and his route
to the bathroom is a major career booster."  -- Patrick Naughton

Attachment: cygcheck-20040519.out
Description: Text document

--
Unsubscribe info:      http://cygwin.com/ml/#unsubscribe-simple
Problem reports:       http://cygwin.com/problems.html
Documentation:         http://cygwin.com/docs.html
FAQ:                   http://cygwin.com/faq/

Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]