Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > gnu.bash.bug > #15472

Re: Bug? `set -e` inside functions inside `$(...)`

From Chet Ramey <chet.ramey@case.edu>
Newsgroups gnu.bash.bug
Subject Re: Bug? `set -e` inside functions inside `$(...)`
Date 2019-10-04 08:01 -0400
Organization ITS, Case Western Reserve University
Message-ID <mailman.955.1570190548.2651.bug-bash@gnu.org> (permalink)
References <CADO30sqtGh+O54c0pLic-8YA00VG244gcRY8x8XFv8yHNby5yA@mail.gmail.com> <CADO30spotrQHiTWfKFngTPERSypRz3PgJRh+UA1EKv_D=qGiBQ@mail.gmail.com> <f1ab5ff1-db02-1037-600b-3827aba94179@case.edu>

Show all headers | View raw


On 10/3/19 8:58 PM, John W wrote:
> Ah, got it sorted out.
> 
> Not a bug, of course (:
> 
> Bash, when not in posix mode, clears the '-e' flag in subshell environments.

You might be interested in the `inherit_errexit' option.

-- 
``The lyf so short, the craft so long to lerne.'' - Chaucer
		 ``Ars longa, vita brevis'' - Hippocrates
Chet Ramey, UTech, CWRU    chet@case.edu    http://tiswww.cwru.edu/~chet/

Back to gnu.bash.bug | Previous | Next | Find similar | Unroll thread


Thread

Re: Bug? `set -e` inside functions inside `$(...)` Chet Ramey <chet.ramey@case.edu> - 2019-10-04 08:01 -0400

csiph-web