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


Groups > gnu.bash.bug > #15465

Re: bash sets O_NONBLOCK on pts

Path csiph.com!xmission!news.snarked.org!news.linkpendium.com!news.linkpendium.com!panix!usenet.stanford.edu!not-for-mail
From Matteo Croce <mcroce@redhat.com>
Newsgroups gnu.bash.bug
Subject Re: bash sets O_NONBLOCK on pts
Date Wed, 2 Oct 2019 20:43:35 +0200
Lines 38
Approved bug-bash@gnu.org
Message-ID <mailman.790.1570041858.2651.bug-bash@gnu.org> (permalink)
References <CAGnkfhzCqfL03_Ox+awRvd2gmu+OQy4J8qbzQLiaO3sQgQcGqA@mail.gmail.com> <5d94e361.21745@msgid.achurch.org> <CAGnkfhwz-1DE+yKFGi-yCviQeAE_2h2-p7rhA1xOt7pPzXBdkg@mail.gmail.com> <87tv8r8132.fsf@igel.home> <CAGnkfhzy21_PgxJ3TyipdFBOd-mZxcDZsOaX1rxLxN4ViJJ4iw@mail.gmail.com>
NNTP-Posting-Host lists.gnu.org
Mime-Version 1.0
Content-Type text/plain; charset=UTF-8
Content-Transfer-Encoding quoted-printable
X-Trace usenet.stanford.edu 1570041859 14632 209.51.188.17 (2 Oct 2019 18:44:19 GMT)
X-Complaints-To action@cs.stanford.edu
Cc Andrew Church <achurch@achurch.org>, bug-bash@gnu.org
To Andreas Schwab <schwab@linux-m68k.org>
Envelope-to bug-bash@gnu.org
DKIM-Signature v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1570041855; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=z5Vo8r1ZxaltNY8bIJK6jYfKW3mLyZj9I7z9jCVARRM=; b=h+kYwl17J1CB2uUfmjIZwuDb+WlZy1EYwydZPwyQEpNRsL5vm73bNj7i2PiTv6xWGkqERn jr1jGEoSrSMTkH2b2lLQPSK8kKazolvql+OtOQxyjPc0ww5KGJrnTOoVdE6oc1Bj37lujy ckkJa6irSB7hD0+pn/v98pwuwh1VJRg=
X-Google-DKIM-Signature v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:references:in-reply-to:from:date :message-id:subject:to:cc; bh=wuQ1/kYazGN2JH337d+bSFWpO67N42e4Hofpyycx4CQ=; b=FzhLDlW5idB2wEL9Jnu2ECpEjcg+erFGRgy86bIsX6+2GQ82QWxDvET4oAroActiqq fwr+B5nQyDBItmw1hlugHNlrw2nrAJeafgM9qXLDUsEAR2HZAEIpd/ZheBt9TUNHghyr lCRRarqA4C3LIr5JUyZaYhx9rzOKESeAEcevlsqYfr8j32c3eihXnHVQNxQIaQhGhveZ tD3aH1fAt/+80YenyOs6PVxNU1S0LYY21PIHC/eqJWReV/I3pffnLUJoSxLK2jQQ8JYY FMBfoGbq8tpctSjBE3tmthB2SQZoSYaNjjD4SiGY38bxuRhv6MWiXqgC8rxl/ngJ6E7r YGCA==
X-Gm-Message-State APjAAAVJpRxGWxntmxW4UWPHPC78MoujbuSK57EeNvlyGG2Ij7LrLAg5 IG0mhZvD9SjwiA6Sbky22kwj2S5izgGu/e+aSVb10OeBtwwS/IvUK+oUq1skHSVewogsNhh+hSR d0OmUjdQOsPAsnnFqU2wXVTLa
X-Received by 2002:a2e:5714:: with SMTP id l20mr3488415ljb.122.1570041851496; Wed, 02 Oct 2019 11:44:11 -0700 (PDT)
X-Google-Smtp-Source APXvYqxE+ycr1e0Iqegp6P85zaFFzGRYUwkIhXnDxFyNnCJITuxJx7MBMDhT69vZccUBcuk7aqjakZaktrQK+/nNB54=
X-Received by 2002:a2e:5714:: with SMTP id l20mr3488410ljb.122.1570041851327; Wed, 02 Oct 2019 11:44:11 -0700 (PDT)
In-Reply-To <87tv8r8132.fsf@igel.home>
X-MC-Unique D-eKjeHFP3S4jsSfBDpfPQ-1
X-Mimecast-Spam-Score 0
X-detected-operating-system by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic] [fuzzy]
X-Received-From 207.211.31.120
X-BeenThere bug-bash@gnu.org
X-Mailman-Version 2.1.23
Precedence list
List-Id Bug reports for the GNU Bourne Again SHell <bug-bash.gnu.org>
List-Unsubscribe <https://lists.gnu.org/mailman/options/bug-bash>, <mailto:bug-bash-request@gnu.org?subject=unsubscribe>
List-Archive <https://lists.gnu.org/archive/html/bug-bash>
List-Post <mailto:bug-bash@gnu.org>
List-Help <mailto:bug-bash-request@gnu.org?subject=help>
List-Subscribe <https://lists.gnu.org/mailman/listinfo/bug-bash>, <mailto:bug-bash-request@gnu.org?subject=subscribe>
X-Mailman-Original-Message-ID <CAGnkfhzy21_PgxJ3TyipdFBOd-mZxcDZsOaX1rxLxN4ViJJ4iw@mail.gmail.com>
X-Mailman-Original-References <CAGnkfhzCqfL03_Ox+awRvd2gmu+OQy4J8qbzQLiaO3sQgQcGqA@mail.gmail.com> <5d94e361.21745@msgid.achurch.org> <CAGnkfhwz-1DE+yKFGi-yCviQeAE_2h2-p7rhA1xOt7pPzXBdkg@mail.gmail.com> <87tv8r8132.fsf@igel.home>
Xref csiph.com gnu.bash.bug:15465

Show key headers only | View raw


On Wed, Oct 2, 2019 at 8:16 PM Andreas Schwab <schwab@linux-m68k.org> wrote:
>
> On Okt 02 2019, Matteo Croce <mcroce@redhat.com> wrote:
>
> > It seems to me that bash restores the flag, cat prints an error when not:
> >
> > $ cat
> > $
> >
> > the same is not true if running multiple commands:
> >
> > $ ./foo; cat
> > cat: -: Resource temporarily unavailable
> > $
> >
> > Why this different behaviour?
>
> Because it's reset immediately before reading the next line with
> readline.
>
> Andreas.
>
> --
> Andreas Schwab, schwab@linux-m68k.org
> GPG Key fingerprint = 7578 EB47 D4E5 4D69 2510  2552 DF73 E780 A9DA AEC1
> "And now for something completely different."

Exactly, while in my bug I can do any command I want without resetting it.
Only `exec bash` restores it.

-- 
Matteo Croce
per aspera ad upstream

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


Thread

Re: bash sets O_NONBLOCK on pts Matteo Croce <mcroce@redhat.com> - 2019-10-02 20:43 +0200

csiph-web