Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > gnu.bash.bug > #15281

Re: Incorrect passing of argc argv with multiple redirects

From Eduardo Bustamante <dualbus@gmail.com>
Newsgroups gnu.bash.bug
Subject Re: Incorrect passing of argc argv with multiple redirects
Date 2019-07-30 10:56 -0700
Message-ID <mailman.285.1564509405.1985.bug-bash@gnu.org> (permalink)
References <CANY-LFLTkqOyooA522KwuB1JEiaiUQ=N-5XEVWxueO14WLWWvQ@mail.gmail.com> <CAOSMAut7+h1mLBaBs=-J7yyBfh8SZ+C8VVDhtMUS9Afx6KeQrQ@mail.gmail.com>

Show all headers | View raw


On Tue, Jul 30, 2019 at 10:35 AM Morgan McClure
<mcclure.morgan@gmail.com> wrote:
(...)
> ./a.out foo > /dev/null 2&>1; echo $?
>     returns 3 NOT as expected

Are you 100% certain the `2&>1` redirection means what you think it
means? (hint: I recommend reading the "Redirecting Standard Output and
Standard Error" section of the bash manual, check if the leading `2`
is valid there).

Back to gnu.bash.bug | Previous | Next | Find similar | Unroll thread


Thread

Re: Incorrect passing of argc argv with multiple redirects Eduardo Bustamante <dualbus@gmail.com> - 2019-07-30 10:56 -0700

csiph-web