Re: bash drops errexit option in sourced file

2012-12-03 Thread Chet Ramey
On 12/3/12 11:07 AM, Chet Ramey wrote: > On 12/3/12 10:50 AM, Robert Schiele wrote: >> On Mon, Dec 3, 2012 at 4:25 PM, Chet Ramey wrote: >>> Since the `source' command is called in a context where all commands within >>> it should have the `errexit' flag disabled, bash chooses to satisfy this >>>

Re: bash drops errexit option in sourced file

2012-12-03 Thread Chet Ramey
On 12/3/12 10:50 AM, Robert Schiele wrote: > On Mon, Dec 3, 2012 at 4:25 PM, Chet Ramey wrote: >> Since the `source' command is called in a context where all commands within >> it should have the `errexit' flag disabled, bash chooses to satisfy this >> requirement by turning off the flag that (int

Re: bash drops errexit option in sourced file

2012-12-03 Thread Robert Schiele
On Mon, Dec 3, 2012 at 4:25 PM, Chet Ramey wrote: > Since the `source' command is called in a context where all commands within > it should have the `errexit' flag disabled, bash chooses to satisfy this > requirement by turning off the flag that (internally) represents errexit. > Under most circum

Re: bash drops errexit option in sourced file

2012-12-03 Thread Chet Ramey
On 12/3/12 4:12 AM, Robert Schiele wrote: > Bash Version: 4.2 > Patch Level: 24 > Release Status: release > > Description: > While normally sourced files have identical options set like the > invoking environment this is not true if the sourcing is done from > within a function foo that was calle

bash drops errexit option in sourced file

2012-12-03 Thread Robert Schiele
Configuration Information [Automatically generated, do not change]: Machine: x86_64 OS: linux-gnu Compiler: gcc -I/home/abuild/rpmbuild/BUILD/bash-4.2 -L/home/abuild/rpmbuild/BUILD/bash-4.2/../readline-6.2 Compilation CFLAGS: -DPROGRAM='bash' -DCONF_HOSTTYPE='x86_64' -DCONF_OSTYPE='linux-gnu' -DCO