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
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
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
>>
>> task_in_background () {
>> echo "subshell $BASHPID"
>>
>> while :; do
>>
Chester,
You could you clarify/help, please ?
On Wed, Oct 17, 2012 at 11:13 AM, Francis Moreau wrote:
> On Tue, Oct 16, 2012 at 10:00 PM, Bob Proulx wrote:
>> Francis Moreau wrote:
>>> --
>>> main_cleanup () { echo main cleanup; }
>>> submain_cleanup () { echo sub cleanup; }
>>>
>>>
On Tue, Oct 16, 2012 at 10:00 PM, Bob Proulx wrote:
> Francis Moreau wrote:
>> --
>> main_cleanup () { echo main cleanup; }
>> submain_cleanup () { echo sub cleanup; }
>>
>> trap main_cleanup EXIT
>>
>> task_in_background () {
>> echo "subshell $BASHPID"
>>
>> while :;
Francis Moreau wrote:
> --
> main_cleanup () { echo main cleanup; }
> submain_cleanup () { echo sub cleanup; }
>
> trap main_cleanup EXIT
>
> task_in_background () {
> echo "subshell $BASHPID"
>
> while :; do
> # echo "FOO"
> sleep 1
>
Thanks for your prompt answer.
On Tue, Oct 16, 2012 at 7:31 PM, DJ Mills wrote:
> On Tue, Oct 16, 2012 at 1:26 PM, Francis Moreau
> wrote:
>> Hi,
>>
>> Currently the description of the builtin trap isn't enough regarding
>> the description of the EXIT signal spec, IMHO.
>>
>> It says: "If a SIG
On Tue, Oct 16, 2012 at 1:26 PM, Francis Moreau wrote:
> Hi,
>
> Currently the description of the builtin trap isn't enough regarding
> the description of the EXIT signal spec, IMHO.
>
> It says: "If a SIGNAL_SPEC is EXIT (0) ARG is executed on exit from
> the shell.", and nothing more, unless I'm
Hi,
Currently the description of the builtin trap isn't enough regarding
the description of the EXIT signal spec, IMHO.
It says: "If a SIGNAL_SPEC is EXIT (0) ARG is executed on exit from
the shell.", and nothing more, unless I'm missing some other points
about it somewhere else (that would be un