From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from groucho.cs.psu.edu ([130.203.2.10]) by archone.tamu.edu with SMTP id <45323>; Tue, 7 Apr 1992 20:53:06 -0500 Received: by groucho.cs.psu.edu id <2538>; Tue, 7 Apr 1992 21:52:39 -0400 From: Scott Schwartz To: rc@archone.tamu.edu Subject: Reentrant runtime systems considered long overdue (sigwinch bug) Message-Id: <92Apr7.215239edt.2538@groucho.cs.psu.edu> Date: Tue, 7 Apr 1992 20:52:38 -0500 Signals are evil. It looks like the sigwinch thing is going wrong because, by the time rc_read returns in fdgchar, errno has been altered by a system call---stat in this case. Hence the check for errno==EINTR never works out, and bad things happen. The error "No such file or directory" isn't something read can return. That's a clue to the real source of the error, which is the stat call in rc_access, called inside the interrupt handler when it tries to run e.g. stty and has to check a number of entries in your path. That stat call is (in this instance) the last time errno gets set before the longjmp out of the read in rc_read. Tossing an errno=EINTR after the stat mitigates the problem. -- Scott