Zsh Mailing List Archive
Messages sorted by:
Reverse Date,
Date,
Thread,
Author
Re: <(...), >(...) and fds above 9
- X-seq: zsh-workers 44473
- From: Peter Stephenson <p.stephenson@xxxxxxxxxxx>
- To: <zsh-workers@xxxxxxx>
- Subject: Re: <(...), >(...) and fds above 9
- Date: Mon, 1 Jul 2019 16:28:28 +0100
- Cms-type: 201P
- Dkim-filter: OpenDKIM Filter v2.11.0 mailout2.w1.samsung.com 20190701152831euoutp027508281a165c0bed36af3f84d8cf40b6~tUhi8HDUN2111321113euoutp02t
- Dkim-signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=samsung.com; s=mail20170921; t=1561994911; bh=ZCrVMdyx6wO2MmzZxRIrQkKQn3RvNu2M0XW9YV9rXek=; h=Subject:From:To:Date:In-Reply-To:References:From; b=R5Uw6KVOzCErIzR8Gq8qvU1sis1G0C/BkqSq9twNNC2ANQxGGmCcy2v23LvJBiPJr XNO3DDRV4T+FXYPSEUDhyu3iAfS2aulKPK15JLBvvm/4f7LGuH5TmU8l6PRiHAQob5 Fl3CWiTUzQ3pjGi+Qp130Vg5/RWkyMihxLYuQpWw=
- In-reply-to: <CAH+w=7Z+UBP-0ZvHbNzfz13a7e4AFGpQyuntEaKNENeLRDdmVQ@mail.gmail.com>
- List-help: <mailto:zsh-workers-help@zsh.org>
- List-id: Zsh Workers List <zsh-workers.zsh.org>
- List-post: <mailto:zsh-workers@zsh.org>
- List-unsubscribe: <mailto:zsh-workers-unsubscribe@zsh.org>
- Mailing-list: contact zsh-workers-help@xxxxxxx; run by ezmlm
- References: <CGME20190701100058epcas2p25e5f8dbd14d048fe2be1d831f3cf60ab@epcas2p2.samsung.com> <20190701100001.hbegs7zyu2auckhf@chaz.gmail.com> <1561975733.6006.2.camel@samsung.com> <CAH+w=7Z+UBP-0ZvHbNzfz13a7e4AFGpQyuntEaKNENeLRDdmVQ@mail.gmail.com>
On Mon, 2019-07-01 at 07:39 -0700, Bart Schaefer wrote:
> On Mon, Jul 1, 2019 at 3:09 AM Peter Stephenson
> <p.stephenson@xxxxxxxxxxx> wrote:
> >
> >
> > On Mon, 2019-07-01 at 11:00 +0100, Stephane Chazelas wrote:
> > >
> > >
> > > It seems fds above 9 are closed in those forms of process substitutions.
> > >
> > > It doesn't happen for the =(...) form of process substitution.
> > >
> > > Is that intentional?
> > I'd be surprised if there was any deliberate intention to make these different,
> > but there may be some detail I can't think of.
> <(...) does
> entersubsh(ESUB_ASYNC|ESUB_PGRP, NULL);
>
> whereas =(...) does
> entersubsh(ESUB_PGRP|ESUB_NOMONITOR, NULL);
>
> The fds above 9 are only closed for ASYNC, I think.
I don't think entersubsh() calls closem() --- it's
usually done at other points, either in execute()
or a special execution function in the case of the
various process-style substitutions.
Looks like =(...) doesn't call closem() at all when
forking, hence the difference in behaviour. So
=(...) is the odd one out.
pws
Messages sorted by:
Reverse Date,
Date,
Thread,
Author