From: Rich Felker <dalias@aerifal.cx>
To: musl@lists.openwall.com
Subject: Re: minor fixes
Date: Sun, 25 Sep 2011 12:14:10 -0400 [thread overview]
Message-ID: <20110925161410.GN132@brightrain.aerifal.cx> (raw)
In-Reply-To: <20110925134725.GA24939@port70.net>
On Sun, Sep 25, 2011 at 03:47:25PM +0200, Szabolcs Nagy wrote:
> attached a few lines of small changes
>
>
> * if the time.h fixme is because of the sigevent struct
> declaration, then it can go away as posix says
> "The tag sigevent shall be declared as naming an incomplete structure type,
> the contents of which are described in the <signal.h> header."
>
> actually there is a much stronger statement as well:
> "Inclusion of the <time.h> header may make visible all symbols from the
> <signal.h> header."
OK, I guess this is what the comment was about. Actually I forgot what
it was there for. :-)
> * __syscall_ret: declaration should be consistent with the function
> definition (argument is signed long)
>
> i think one of the (unsigned long) casts is unnecessary due to conversion
> rules but it probably makes things more clear
I want to keep the types from the function definition and fix the
prototype. They were basically chosen so that the "ugly"
(impl-defined) conversion (unsigned-to-signed) would always take place
inside the implementation of this function, and the safe
(signed-to-unsigned) conversion could take place implicitly in the
caller if necessary. It probably doesn't matter but I thought it
cleaner at the time.
> * sbrk: changed prototype here as well to be consistent with the standard
>
> actually semantically ptrdiff_t is better (sbrk does p+arg, not p=arg)
> but the standard uses intptr_t
>
> this change should not hurt as sbrk should not be used anyway..
> (i guess there is no architecture where intptr_t != ptrdiff_t)
I agree, this is the right fix.
> * __asctime: use new crash (i assume the *0=0 crash is deprecated now)
Good catch.
> * setpgid: pid_t return type is wrong (return value is an error code)
This one too.
Thanks!
Rich
next prev parent reply other threads:[~2011-09-25 16:14 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2011-09-25 13:47 Szabolcs Nagy
2011-09-25 16:14 ` Rich Felker [this message]
2011-09-26 17:07 ` Szabolcs Nagy
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=20110925161410.GN132@brightrain.aerifal.cx \
--to=dalias@aerifal.cx \
--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).