Zsh Mailing List Archive
Messages sorted by: Reverse Date, Date, Thread, Author

Re: I/O to shell function in zsh coproc



On Sat, 05 Feb 2011 10:08:16 -0800
Bart Schaefer <schaefer@xxxxxxxxxxxxxxxx> wrote:
> You're right, there is a bug there.  I'm not immediately sure where to
> fix it, but there's a workaround.
> 
> The bug is that when you do 'coproc shellfunction', zsh has to fork a
> subshell to run the shellfunction in another process.  The trouble is
> that the subshell therefore gets copies of the coprocess descriptors
> that are open in the parent shell.

(More dirty washing also moved to zsh-workers.)

It's not as simple as setting FD_CLOEXEC for coproc descriptors, then?

-- 
Peter Stephenson <p.w.stephenson@xxxxxxxxxxxx>
Web page now at http://homepage.ntlworld.com/p.w.stephenson/



Messages sorted by: Reverse Date, Date, Thread, Author