Re: [dev] [quark] Performance issues

From: Markus Wichmann <>
Date: Wed, 25 Sep 2019 17:03:06 +0200

On Wed, Sep 25, 2019 at 04:32:45PM +0200, Laslo Hunhold wrote:
> please excuse the ignorant question, but why would you want to access
> /dev/null? The problem with /dev/urandom is well-known, which is why
> OpenBSD has arc4random(3).

You might not, but a library you use might. I remember musl testing for
open FDs 0, 1, and 2 and opening /dev/null to make up for missing FDs.
And crashing (deliberately) if that fails. But then, that only happens
for elevated security contexts, i.e. setuid or "secure" mode (which on
Linux means "file capabilities set").

/dev/null has the distinction of being the only device POSIX actually
requires. I don't know what you might use it for. (/dev/tty is
defined, but optional.)

Received on Wed Sep 25 2019 - 17:03:06 CEST

This archive was generated by hypermail 2.3.0 : Wed Sep 25 2019 - 18:24:09 CEST