Re: Clarification needed on signal spec EXIT

2012-10-21 Thread Francis Moreau
Thanks for answering, however... On Sat, Oct 20, 2012 at 9:01 PM, Chet Ramey wrote: > On 10/16/12 4:00 PM, Bob Proulx wrote: >> Francis Moreau wrote: >>> -- >>> main_cleanup () { echo main cleanup; } >>> submain_cleanup () { echo sub cleanup; } >>> >>> trap main_cleanup EXIT >>> >>> t

Re: Clarification needed on signal spec EXIT

2012-10-21 Thread Chet Ramey
On 10/21/12 7:35 AM, Francis Moreau wrote: >> Yes, this is a bug in bash-4.2. The subshell doesn't properly reinitialize >> the traps if a trap has already been set in the parent. This was fixed in >> late July and will be in the next version of bash. > > That doesn't explain the following (tak