From: Szabolcs Nagy <nsz@port70.net>
To: musl@lists.openwall.com
Subject: Re: Add login_tty
Date: Sat, 1 Nov 2014 23:07:08 +0100 [thread overview]
Message-ID: <20141101220708.GI10829@port70.net> (raw)
In-Reply-To: <20141101214503.GK22465@brightrain.aerifal.cx>
* Rich Felker <dalias@libc.org> [2014-11-01 17:45:03 -0400]:
> >
> > I still don't understand how dup2 can fail when fd 0/1/2 are not open in
> > the parent. AFAIU, limits on the number of open fds are imposed by an
> > upper bound on the value of any fd. For the dup2 calls we know that the
> > newfds are certainly within the limits.
>
> Indeed, looking at the kernel code, I don't see any error paths where
> this operation could fail. I had figured some allocations might be
> needed to represent the new fd in the fd table, but it seems not. So
> the current code is probably unnecessary.
>
i think with seccomp syscall filtering anything can fail
although libc probably dont have to take that into account
next prev parent reply other threads:[~2014-11-01 22:07 UTC|newest]
Thread overview: 27+ messages / expand[flat|nested] mbox.gz Atom feed top
2014-08-25 18:57 Felix Janda
2014-08-25 22:43 ` Rich Felker
2014-08-26 16:56 ` Felix Janda
2014-08-29 18:44 ` Felix Janda
2014-09-04 21:22 ` Szabolcs Nagy
2014-09-04 21:33 ` Rich Felker
2014-09-04 22:31 ` Justin Cormack
2014-09-05 17:23 ` Felix Janda
2014-09-05 17:29 ` Rich Felker
2014-09-05 18:52 ` Felix Janda
2014-10-31 16:19 ` Rich Felker
2014-11-01 21:15 ` Felix Janda
2014-11-01 21:45 ` Rich Felker
2014-11-01 22:07 ` Szabolcs Nagy [this message]
2014-11-01 22:27 ` Felix Janda
2014-11-01 22:43 ` Rich Felker
2014-11-01 22:56 ` Felix Janda
2014-11-02 0:09 ` Rich Felker
2014-11-02 14:19 ` Felix Janda
2014-11-02 16:28 ` Rich Felker
2014-11-02 18:56 ` Felix Janda
2014-11-02 22:28 ` Rich Felker
2014-11-03 18:29 ` Felix Janda
2014-12-21 0:58 ` Rich Felker
2014-12-21 1:15 ` Rich Felker
2014-12-21 1:38 ` Rich Felker
2014-12-21 2:59 ` Rich Felker
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20141101220708.GI10829@port70.net \
--to=nsz@port70.net \
--cc=musl@lists.openwall.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
Code repositories for project(s) associated with this public inbox
https://git.vuxu.org/mirror/musl/
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).