delorie.com/archives/browse.cgi   search  
Mail Archives: djgpp-workers/2001/05/10/14:32:11

From: "Tim Van Holder" <tim DOT van DOT holder AT pandora DOT be>
To: <djgpp-workers AT delorie DOT com>
Subject: Re: Bash 2.04 beta 1 now available
Date: Thu, 10 May 2001 20:30:00 +0200
Message-ID: <CAEGKOHJKAAFPKOCLHDIAEDCCDAA.tim.van.holder@pandora.be>
MIME-Version: 1.0
X-Priority: 3 (Normal)
X-MSMail-Priority: Normal
X-Mailer: Microsoft Outlook IMO, Build 9.0.2416 (9.0.2910.0)
In-Reply-To: <3AF9D8D3.6219.35A724@localhost>
Importance: Normal
X-MimeOLE: Produced By Microsoft MimeOLE V5.50.4133.2400
Reply-To: djgpp-workers AT delorie DOT com
Errors-To: nobody AT delorie DOT com
X-Mailing-List: djgpp-workers AT delorie DOT com
X-Unsubscribes-To: listserv AT delorie DOT com

Seems like bash has another bug/feature, triggered by the
following snippet from autoheader:

$verbose $me: sourcing $tmp/traces.sh >&2
if (set -e && . $tmp/traces.sh) >/dev/null 2>&1; then
  . $tmp/traces.sh
else
  echo "$me: error: shell error while sourcing $tmp/trace.sh" >&2
  (exit 1); exit
fi

The 'set -e' is supposed to cause the subshell to exit if sourcing
the shell fragment fails.  However, it seems that our bash exits
_completely_ if such a set -e failure is hit in a subshell.

For example:

c:\> bash
$ (echo a; (echo b); echo c)
a
b
c
$ (echo a; (echo b; set -e && false); echo c)
a
b

c:\>

- Raw text -


  webmaster     delorie software   privacy  
  Copyright © 2019   by DJ Delorie     Updated Jul 2019