From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 12091 invoked from network); 31 Jan 2000 12:07:51 -0000 Received: from sunsite.auc.dk (130.225.51.30) by ns1.primenet.com.au with SMTP; 31 Jan 2000 12:07:51 -0000 Received: (qmail 2976 invoked by alias); 31 Jan 2000 12:07:46 -0000 Mailing-List: contact zsh-workers-help@sunsite.auc.dk; run by ezmlm Precedence: bulk X-No-Archive: yes X-Seq: 9497 Received: (qmail 2968 invoked from network); 31 Jan 2000 12:07:46 -0000 Date: Mon, 31 Jan 2000 13:07:45 +0100 (MET) Message-Id: <200001311207.NAA01858@beta.informatik.hu-berlin.de> From: Sven Wischnowsky To: zsh-workers@sunsite.auc.dk In-reply-to: "Bart Schaefer"'s message of Sun, 30 Jan 2000 18:47:00 +0000 Subject: Re: Problems with trap handling? Bart Schaefer wrote: > This may be related to my "infinite loop" report: > > function tst() { > trap return INT > read -q xx'?Type ^C here: ' > echo You should not see this. > } > > Execute in 3.1.6-dev-16 and type ^C. Note that you don't leave the "read" > prompt. Type any plain character; now "read" returns, and the function > aborts as if interrupted. Completely different problem. No patch yet -- I'm not sure: In this incanartion read ends up in read1char() which explicitly does *not* stop if the read returns with errno==EINTR. So I guess someone had a reason for doing this way. We could either test retflag/breaks/contflag there or give it a flag that says to stop in case of EINTR and which would be set by bin_read (via getquery()). Of course, there are also be other solutions... Bye Sven -- Sven Wischnowsky wischnow@informatik.hu-berlin.de