Zsh Mailing List Archive
Messages sorted by:
Reverse Date,
Date,
Thread,
Author
Re: detect pipe
On 2021-02-14 12:33:35 -0800, Ray Andrews wrote:
> On 2021-02-14 11:33 a.m., Bart Schaefer wrote:
> > On Sun, Feb 14, 2021 at 9:31 AM Vincent Lefevre <vincent@xxxxxxxxxx> wrote:
> > > Closing stdin is a bad idea, as this can break stdout redirection,
> > > and this may be out of control of the commands. See
> > >
> > > https://sourceware.org/bugzilla/show_bug.cgi?id=682
> > IMO that's just silly. If stdin/stdout were never supposed to be
> > closed, why has the standard shell had <&- and >&- for its entire
> > existence? Why wouldn't those be syntax errors when a file descriptor
> > number is not provided if you're never supposed to use them?
> >
> If it is closed, where does input go? Queued up or vanish?
I don't see any difference with a command, like "true", that doesn't
read anything.
--
Vincent Lefèvre <vincent@xxxxxxxxxx> - Web: <https://www.vinc17.net/>
100% accessible validated (X)HTML - Blog: <https://www.vinc17.net/blog/>
Work: CR INRIA - computer arithmetic / AriC project (LIP, ENS-Lyon)
Messages sorted by:
Reverse Date,
Date,
Thread,
Author