From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 578 invoked by alias); 9 Sep 2010 08:09:05 -0000 Mailing-List: contact zsh-users-help@zsh.org; run by ezmlm Precedence: bulk X-No-Archive: yes List-Id: Zsh Users List List-Post: List-Help: X-Seq: 15374 Received: (qmail 5132 invoked from network); 9 Sep 2010 08:09:00 -0000 X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on f.primenet.com.au X-Spam-Level: X-Spam-Status: No, score=-1.9 required=5.0 tests=BAYES_00,FREEMAIL_FROM, RCVD_IN_DNSWL_NONE,T_TO_NO_BRKTS_FREEMAIL autolearn=ham version=3.3.1 Received-SPF: pass (ns1.primenet.com.au: SPF record at gmx.de designates 213.165.64.23 as permitted sender) Content-Type: multipart/mixed; boundary="========GMX763212840193343021" Date: Thu, 09 Sep 2010 10:02:14 +0200 From: "Dominik Vogt" Message-ID: <20100909080214.76320@gmx.net> MIME-Version: 1.0 Subject: trap does not work in a trap function? To: zsh-users@zsh.org X-Authenticated: #885628 X-Flags: 0001 X-Mailer: WWW-Mail 6100 (Global Message Exchange) X-Priority: 3 X-Provags-ID: V01U2FsdGVkX1+XjV106NWXFR05+VSH8SeMlM9EMUbtqoLaHiEKe4 OtLXc4b44K8mRh0b30IKrhWN8wX4nL6yJ1kw== X-GMX-UID: saK7eLJVTXsuQg/nbGQ5s4RCRzdyMsMp X-FuHaFi: 0.75 --========GMX763212840193343021 Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: 8bit The attached small script behaves in an unexpected way (at least to me): $ ./sigtest shutdown shutdown Why is the shutdown function called again by exit when the EXIT trap was just removed? This looks like the trap builtin does not properly work from within a trap handler. -- Achtung Sicherheitswarnung: GMX warnt vor Phishing-Attacken! http://portal.gmx.net/de/go/sicherheitspaket --========GMX763212840193343021--