bug-bash
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Issue when using job control and SIGCHLD with bash 4.3 (trap is not


From: Chet Ramey
Subject: Re: Issue when using job control and SIGCHLD with bash 4.3 (trap is not being run)
Date: Mon, 14 Apr 2014 17:05:48 -0400
User-agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.9; rv:24.0) Gecko/20100101 Thunderbird/24.4.0

On 4/14/14, 4:25 PM, Eduardo A. Bustamante López wrote:
> Hi,
> 
> I was playing with set -m and trapping CHLD in a script, and found
> the following error:

Thanks for the report.  I'll take a look.

> As you can notice, bash 4.3 exits earlier. It should do 5 iterations,
> but instead, it only completes 3. I found that is has something to do
> with using queue_sigchld_trap instead of run_sigchld_trap, which I
> assume fixes another issue, but the fix introduced this error.

It may have something to do with that, but the attached patch is not the
correct one: you can't run arbitrary functions in a signal handler
context.

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



reply via email to

[Prev in Thread] Current Thread [Next in Thread]