[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: unwanted warning "execute_coproc: coproc [$PID:.*] still exists"
From: |
Chet Ramey |
Subject: |
Re: unwanted warning "execute_coproc: coproc [$PID:.*] still exists" |
Date: |
Tue, 12 Apr 2011 16:50:18 -0400 |
User-agent: |
Mozilla/5.0 (Macintosh; U; Intel Mac OS X 10.5; en-US; rv:1.9.2.15) Gecko/20110303 Thunderbird/3.1.9 |
On 4/7/11 8:06 AM, sbrabec@suse.cz wrote:
> Bash Version: 4.1
> Patch Level: 10
> Release Status: release
>
> Description:
> Warning "execute_coproc: coproc [$PID:.*] still exists" as it is
> implemented makes no sense. It appears in many situations where
> it is done intentionally and it is not easy to silence it.
>
> If writing values of PID and I/O channels does not overwrite old
> values, I see no reason to issue this warning.
>
> Repeat-By:
> coproc a ( cat )
> coproc b ( cat )
> bash: warning: execute_coproc: coproc [13690:b] still exists
>
> Fix:
> The warning should be issued only if the old process still
> exists AND array which should store the coproc data is not
> empty.
The warnings exist because there is really only one shell coproc
internally. You can do a lot with the arrays and shell builtins, but
as the man page says under BUGS:
There may be only one active coprocess at a time.
(The shell will forget about earlier coprocs and not mark them as
completed, for instance.)
There is some support for multiple coprocs, and if there is sufficient
need, I will finish it. I'm waiting to see whether or not there is a
need for more than one simultaneous coproc -- I don't have a lot of
reports of coproc use.
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/