[klibc] Bug#516294: On the trail of sigsuspend(2)

Thorsten Glaser tg at mirbsd.de
Sat Jan 29 15:52:39 PST 2011


Dixi quod…

>root at ara2:~ # klcc -o tklibc t.c; gcc -o tglibc t.c; ./tklibc; ./tglibc
>4
>128

Hm. Apparently, it’s not that, because klibc appears to use the
old-style functions and old_sigset_t is a long, so okay. (And
no, it’s not related to that commit, 1.5.20 was broken too.)

strace ./mksh -c ls    shows:
sigsuspend([INT ILL USR1 USR2 ALRM CHLD CONT STOP WINCH]

Funnily enough, strace /bin/mksh -c ls says:
rt_sigsuspend([])                       = ? ERESTARTNOHAND (To be restarted)

Now, from what I can gather from the manpages (this signal stuff
is not my code and way past me by now, especially considering the
time of day), sigprocmask() fills in &sm_default which is used as
sigsuspend() argument in the only place it’s called.

Still, one has to wonder whether it’s related to this:
- ticket: http://dev.haiku-os.org/ticket/5567
- commit: http://dev.haiku-os.org/changeset/35836
The symptoms are the same.

bye,
//mirabilos
-- 
I believe no one can invent an algorithm. One just happens to hit upon it
when God enlightens him. Or only God invents algorithms, we merely copy them.
If you don't believe in God, just consider God as Nature if you won't deny
existence.		-- Coywolf Qi Hunt



More information about the klibc mailing list