summaryrefslogtreecommitdiff
path: root/src/thread/pthread_create.c
diff options
context:
space:
mode:
authorRich Felker <dalias@aerifal.cx>2013-04-26 17:30:32 -0400
committerRich Felker <dalias@aerifal.cx>2013-04-26 17:30:32 -0400
commit082fb4e9bfd105fab3443c7b055bd9c22bdffcec (patch)
treef601fc5c5707422db63cfe8bd586d1091fea1c24 /src/thread/pthread_create.c
parentd0ba09837bc033e236e921304b213daea0fe2653 (diff)
downloadmusl-082fb4e9bfd105fab3443c7b055bd9c22bdffcec.tar.gz
fix clobbering of signal mask when creating thread with sched attributes
this was simply a case of saving the state in the wrong place.
Diffstat (limited to 'src/thread/pthread_create.c')
-rw-r--r--src/thread/pthread_create.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/thread/pthread_create.c b/src/thread/pthread_create.c
index 5d5d3a6f..cf9cb191 100644
--- a/src/thread/pthread_create.c
+++ b/src/thread/pthread_create.c
@@ -197,7 +197,7 @@ int pthread_create(pthread_t *restrict res, const pthread_attr_t *restrict attrp
if (attr._a_sched) {
do_sched = new->startlock[0] = 1;
__syscall(SYS_rt_sigprocmask, SIG_BLOCK,
- SIGALL_SET, self->sigmask, _NSIG/8);
+ SIGALL_SET, new->sigmask, _NSIG/8);
}
new->unblock_cancel = self->cancel;
new->canary = self->canary;