mailing list of musl libc
 help / color / mirror / code / Atom feed
* [musl] Bug in src/signal/block.c
@ 2021-07-28 15:00 Jasper Hugunin
  2021-07-28 15:53 ` Rich Felker
  0 siblings, 1 reply; 8+ messages in thread
From: Jasper Hugunin @ 2021-07-28 15:00 UTC (permalink / raw)
  To: musl

[-- Attachment #1: Type: text/plain, Size: 904 bytes --]

Hello,

In musl, as far as I can tell, `_NSIG` is always defined as either 65, or
128 (for all three MIPS architectures) at the bottom of
`${arch}/bits/signal.h`. Meanwhile, in `src/signal/block.c`, there is a
test `#if ULONG_MAX == 0xffffffff && _NSIG == 129`, which will never
succeed since _NSIG will be 128 instead of 129. This seems likely to be
left over from Commit: fix _NSIG and SIGRTMAX on mips
<https://git.musl-libc.org/cgit/musl/commit/arch?id=7c440977db9444d7e6b1c3dcb1fdf4ee49ca4158>
.

I have not demonstrated the bug, I found it by inspection of the source. My
guess is that this bug causes __block_all_sigs to fail to block high real
time signals on MIPS. At best, however, this test seems to be dead code.

(I am not subscribed to the mailing list; please cc me directly on any
responses I need to see.)
My apologies if I have misunderstood the situation.

Sincerely,
- Jasper Hugunin

[-- Attachment #2: Type: text/html, Size: 1063 bytes --]

^ permalink raw reply	[flat|nested] 8+ messages in thread

end of thread, other threads:[~2021-07-28 22:05 UTC | newest]

Thread overview: 8+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2021-07-28 15:00 [musl] Bug in src/signal/block.c Jasper Hugunin
2021-07-28 15:53 ` Rich Felker
2021-07-28 17:11   ` Laurent Bercot
2021-07-28 18:43     ` Michael Forney
2021-07-28 19:30     ` Rich Felker
2021-07-28 19:36   ` Rich Felker
2021-07-28 19:52     ` Jasper Hugunin
2021-07-28 22:04       ` Rich Felker

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).