From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from euclid.skiles.gatech.edu (list@euclid.skiles.gatech.edu [130.207.146.50]) by melb.werple.net.au (8.7.5/8.7.3) with ESMTP id WAA16320 for ; Tue, 26 Mar 1996 22:50:00 +1100 (EST) Received: (from list@localhost) by euclid.skiles.gatech.edu (8.7.3/8.7.3) id GAA16016; Tue, 26 Mar 1996 06:33:25 -0500 (EST) Resent-Date: Tue, 26 Mar 1996 06:33:25 -0500 (EST) Date: Tue, 26 Mar 96 12:32:09 +0100 From: braemer@doc.physi.uni-heidelberg.de (Achim Braemer) Message-Id: <9603261132.AA00834@doc.physi.uni-heidelberg.de> To: zsh-workers@math.gatech.edu (Zsh hackers list) Cc: Peter Stephenson Subject: Re: zsh hangs on IRIX 5.2 / me to: (SunOS4.1.3 + Solaris 2.4) In-Reply-To: <9603251055.AA15871@hydra.ifh.de> References: <9603251055.AA15871@hydra.ifh.de> Resent-Message-ID: <"XhaF33.0.Aw3.4OzLn"@euclid> Resent-From: zsh-workers@math.gatech.edu X-Mailing-List: archive/latest/857 X-Loop: zsh-workers@math.gatech.edu Precedence: list Resent-Sender: zsh-workers-request@math.gatech.edu I have put a few printf's in the code and found out that the endless loop of zsh does not occur in the quotes piece of code from zle_main.c. It must be somewhere else, but I have no clue of where to look. Perhaps a signal handling problem? -- Achim -- Peter Stephenson writes on March 25: > leibniz!stucki@leibniz.math.fu-berlin.de wrote: > > - BUT a zsh WAITING FOR A PROCESS TO COMPLETE, > > RUNS FOREVER READING 'nothing' FROM STDIN > > IF THE SUBPROCESS VANISHES AND > > ZSH WAKES UP ON A 'DEAD' TTY. > > You can at least see if this is the problem by removing the > `if (isset(IGNOREEOF)...) continue' and seeing if the problem goes > away. That will have the side-effect that a ^D in typeahead will > cause the shell to exit. > > [part from zle_main.c] > while ((r = read(SHTTY, &cc, 1)) != 1) { > if (r == 0) { > /* The test for IGNOREEOF was added to make zsh ignore ^Ds > that were typed while commands are running. Unfortuantely > this caused trouble under at least one system (SunOS 4.1). > Here shells that lost their xterm (e.g. if it was killed > with -9) didn't fail to read from the terminal but instead > happily continued to read EOFs, so that the above read > returned with 0, and, with IGNOREEOF set, this caused > an infinite loop. The simple way around this was to add > the counter (icnt) so that this happens 20 times and than > the shell gives up (yes, this is a bit dirty...). */ > if (isset(IGNOREEOF) && icnt++ < 20) > continue; > stopmsg = 1; > zexit(1); > } [...]