bug-bash
[Top][All Lists]
Advanced

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

Re: set -m +m -x and the element of chance or is it race conditions?


From: Chet Ramey
Subject: Re: set -m +m -x and the element of chance or is it race conditions?
Date: Sat, 29 Jan 2011 20:51:50 -0500
User-agent: Mozilla/5.0 (Macintosh; U; Intel Mac OS X 10.6; en-US; rv:1.9.2.8) Gecko/20100802 Lightning/1.0b2 Thunderbird/3.1.2

On 1/29/11 7:33 PM, jidanni@jidanni.org wrote:
>>>>>> "CR" == Chet Ramey <chet.ramey@case.edu> writes:
> CR> Is it a problem?  Bash prints messages about signal-terminated processes 
> --
> CR> at least those that don't die due to SIGINT or SIGPIPE -- when the
> CR> shell is not interactive.  Most people want to know when their jobs die
> CR> and their scripts fail.
> 
> But some don't, but also don't want to do exec 2>/dev/null and take
> other messages to the grave with it.
> 
> Plus it isn't documented, depends on having e.g., sleep 0 after it, and
> in general looks like one big hack. And violates the set +mb promise!

Is everything you don't like that's not explicitly documented a bug?  In
any case, a little thought should tell you why having the shell stick
around long enough to catch the child's death makes a difference.

And what is the `set +mb promise'?

> CR> (And, by the way, historical versions of sh did the same thing.)
> But not the oldest.

Umm...yes, the oldest.  The v7 Bourne shell did.  In fact, since we were
running 4.3 BSD back in the early days of working on bash, it's what we
used as a model for this behavior.

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]