[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: process substitution and trailing file descriptors
From: |
Chet Ramey |
Subject: |
Re: process substitution and trailing file descriptors |
Date: |
Thu, 22 Apr 2010 09:37:38 -0400 |
User-agent: |
Mozilla/5.0 (Macintosh; U; Intel Mac OS X 10.5; en-US; rv:1.9.1.9) Gecko/20100317 Thunderbird/3.0.4 |
On 2/11/10 6:04 AM, Ian wrote:
> Basically, by mixing IO redirection and process substitution I'm left
> with a trailing file descriptor which can cause scripts to hang around
> despite any subsequent redirection of stdout/stderr best practices.
> There's no mechanism to discover these new file descriptors and they
> are not closed on exec.
I don't see a good solution to this. The point of process substitution is
to provide processes in the same parent-child tree a handle to an
arbitrary file descriptor without any advance arrangement. This is why
the construct expands to a filename, and why it would defeat the purpose
to make them close-on-exec or arrange to close them in child processes.
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/
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- Re: process substitution and trailing file descriptors,
Chet Ramey <=