Openwall GNU/*/Linux - a small security-enhanced Linux distro for servers
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Date: Fri, 2 Feb 2018 17:01:07 +0100
From: Jens Gustedt <jens.gustedt@...ia.fr>
To: CodingMarkus <CodingMarkus@...auska.name>
Cc: musl@...ts.openwall.com
Subject: Re: Why are stdin/stdout/stderr `FILE *const` in musl?

Hello,

On Fri, 2 Feb 2018 16:30:03 +0100 CodingMarkus
<CodingMarkus@...auska.name> wrote:

> > On 2018-02-02, at 16:01, Markus Wichmann <nullplan@....net> wrote:
> > 
> > Why would you ever need a pointer to stdout or stderr?  
> 
> 
> "Why would you ever need" is no valid argument. It’s no argument for
> anything and especially never an argument against anything.

No, but the exact definition that I gave you from the standard, is
certainly an argument. Did you see this? I didn't see a reply from you
to this.

I checked the provision that this is an expression is there at least
since C99.

> https://git.alpinelinux.org/cgit/aports/tree/main/llvm5/dynamiclibrary-fix-build-musl.patch?id=HEAD

What this shows is that they are clearly wrong in doing

EXPLICIT_SYMBOL(stderr);

stderr is *not* an explicit symbol and should not be.

> And that the people who themselves makes the currently second most
> successful open source compiler on the market act outside the C
> standard doesn’t sound very convincing to me. If in doubt, these
> people know the C standard better than I probably ever will.

Some of them certainly do.

I hope that you are not suggesting that the people that replied to you
here on that list don't know the C standard at least as good.

> I’m only worried with how interchangeable musl is as a standard libc
> because the idea of a standard is that it guarantees compatibility.

exactly, so what they are doing is to be frowned upon

(In particular, because this is a compiler framework that is making
assumptions about the library framework that is not justified.)

> If there are ten libc libraries and they all conform to the same
> standard,

As said in my other mail, this is undefined behavior LaLaLand. So
implementors can do what they want, they don't even have to document
it. But it is just not portable.

Now, if you are claiming that this would be an important feature, one
could certainly at least discuss it. But what I heard so far from you
was only reference to authority (llvm must know what they are doing).
You were not arguing why they are doing this and why this would be
important.

Jens

-- 
:: INRIA Nancy Grand Est ::: Camus ::::::: ICube/ICPS :::
:: ::::::::::::::: office Strasbourg : +33 368854536   ::
:: :::::::::::::::::::::: gsm France : +33 651400183   ::
:: ::::::::::::::: gsm international : +49 15737185122 ::
:: http://icube-icps.unistra.fr/index.php/Jens_Gustedt ::

Content of type "application/pgp-signature" skipped

Powered by blists - more mailing lists

Your e-mail address:

Confused about mailing lists and their use? Read about mailing lists on Wikipedia and check out these guidelines on proper formatting of your messages.