From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 9685 invoked from network); 1 Jun 2005 13:51:08 -0000 Received: from news.dotsrc.org (HELO a.mx.sunsite.dk) (130.225.247.88) by ns1.primenet.com.au with SMTP; 1 Jun 2005 13:51:08 -0000 Received: (qmail 89759 invoked from network); 1 Jun 2005 13:51:02 -0000 Received: from sunsite.dk (130.225.247.90) by a.mx.sunsite.dk with SMTP; 1 Jun 2005 13:51:02 -0000 Received: (qmail 9111 invoked by alias); 1 Jun 2005 13:50:59 -0000 Mailing-List: contact zsh-workers-help@sunsite.dk; run by ezmlm Precedence: bulk X-No-Archive: yes X-Seq: 21298 Received: (qmail 9101 invoked from network); 1 Jun 2005 13:50:59 -0000 Received: from news.dotsrc.org (HELO a.mx.sunsite.dk) (130.225.247.88) by sunsite.dk with SMTP; 1 Jun 2005 13:50:59 -0000 Received: (qmail 89436 invoked from network); 1 Jun 2005 13:50:59 -0000 Received: from vms044pub.verizon.net (206.46.252.44) by a.mx.sunsite.dk with SMTP; 1 Jun 2005 13:50:55 -0000 Received: from candle.brasslantern.com ([4.11.1.68]) by vms044.mailsrvcs.net (Sun Java System Messaging Server 6.2 HotFix 0.04 (built Dec 24 2004)) with ESMTPA id <0IHE00FPPRSR5ED0@vms044.mailsrvcs.net> for zsh-workers@sunsite.dk; Wed, 01 Jun 2005 08:50:52 -0500 (CDT) Received: from candle.brasslantern.com (IDENT:schaefer@localhost [127.0.0.1]) by candle.brasslantern.com (8.12.11/8.12.11) with ESMTP id j51DoonZ009892; Wed, 01 Jun 2005 06:50:50 -0700 Received: (from schaefer@localhost) by candle.brasslantern.com (8.12.11/8.12.11/Submit) id j51DooXS009891; Wed, 01 Jun 2005 06:50:50 -0700 Date: Wed, 01 Jun 2005 13:50:49 +0000 From: Bart Schaefer Subject: Re: Bug#310872: zsh can't be a ksh replacement (can't trap ERR). In-reply-to: <200506011031.j51AV17i010021@news01.csr.com> To: zsh-workers@sunsite.dk Cc: 310872@bugs.debian.org Message-id: <1050601135049.ZM9890@candle.brasslantern.com> MIME-version: 1.0 X-Mailer: Z-Mail (5.0.0 30July97) Content-type: text/plain; charset=us-ascii References: <200505261638.SAA09610@sdt.univ-brest.fr> <20050526191520.GA30061@scowler.net> <42971781.9050402@free.fr> <20050530140616.GA7651@scowler.net> <1050530184143.ZM30459@candle.brasslantern.com> <200506011031.j51AV17i010021@news01.csr.com> Comments: In reply to Peter Stephenson "Re: Bug#310872: zsh can't be a ksh replacement (can't trap ERR)." (Jun 1, 11:31am) X-Spam-Checker-Version: SpamAssassin 3.0.2 on a.mx.sunsite.dk X-Spam-Level: X-Spam-Status: No, score=-2.6 required=6.0 tests=BAYES_00 autolearn=ham version=3.0.2 X-Spam-Hits: -2.6 On Jun 1, 11:31am, Peter Stephenson wrote: } Subject: Re: Bug#310872: zsh can't be a ksh replacement (can't trap ERR). } } Bart Schaefer wrote: } > I note in passing that "trap" in zsh doesn't understand all the same } > signals that "kill" does. For example, when the OS defines both, "kill" } > understands SIGIO as a synonym for SIGPOLL and SIGCLD for SIGCHLD, but } > "trap" only knows CHLD and POLL. } } How did you work this out? I was basing it on an observation of the awk-generated list of trap names on my system and the lack of any explicit mention of CLD and IO elsewhere in the trap code, vs. the presence of alt_sigs in jobs.c. } Adding SIGERR as an alias where there's no system signal is trivial. } Now it should show up in the trap lists under ERR, too. I've removed } the ALT_SIGS definition because there isn't really any justification for } making the mechanism optional now. I can't tell by reading the patch: does this do as Oliver suggested and prefer the ZERR equivalent for ERR, requiring SIGERR to get the actual signal? If not -- that is, if SIGERR is preferred when available -- then we still don't have ksh compatibility.