mirror of
git://git.musl-libc.org/musl
synced 2025-01-01 20:12:04 +00:00
fix spurious EINTR errors from multithreaded set*id, etc.
commit 78a8ef47c4
inadvertently removed
the SA_RESTART flag from the sigaction for the internal signal handler
used by __synccall for broadcasting. as a result, programs which did
not use interrupting signals but which used set*id() in a
multithreaded context could wrongly observe EINTR errors they're not
prepared to handle.
This commit is contained in:
parent
1f53e7d00c
commit
6894f84726
@ -50,7 +50,7 @@ void __synccall(void (*func)(void *), void *ctx)
|
||||
int cs, i, r, pid, self;;
|
||||
DIR dir = {0};
|
||||
struct dirent *de;
|
||||
struct sigaction sa = { .sa_flags = 0, .sa_handler = handler };
|
||||
struct sigaction sa = { .sa_flags = SA_RESTART, .sa_handler = handler };
|
||||
struct chain *cp, *next;
|
||||
struct timespec ts;
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user