|
|
Message-ID: <20261129185016.GE5716@brightrain.aerifal.cx> Date: Sun, 29 Nov 2026 13:50:17 -0500 From: Rich Felker <dalias@...c.org> To: Markus Wichmann <nullplan@....net> Cc: musl@...ts.openwall.com, 吴尚哲 <wushangzhe26@....pku.edu.cn> Subject: Re: Bug in ualarm(): reads uninitialized timer data after setitimer() fails On Sun, Nov 29, 2026 at 07:11:37PM +0100, Markus Wichmann wrote: > Am Sun, Nov 29, 2026 at 10:04:05AM -0500 schrieb Rich Felker: > > Unfortunately ualarm has no specified contract for returning an error. > > I'm not sure what the best way to handle it is. Maybe we can normalize > > the time? > > > > Rich > > glibc will return -1 on setitimer() failure. The obsolete POSIX spec for ualarm from issue 6: https://pubs.opengroup.org/onlinepubs/007904875/functions/ualarm.html specified "No errors are defined". And indeed our current code is just wrong due to how setitimer handles denormalized timevals. We need to be normalizing it. Rich
Powered by blists - more mailing lists
Confused about mailing lists and their use? Read about mailing lists on Wikipedia and check out these guidelines on proper formatting of your messages.