aboutsummaryrefslogtreecommitdiffstats
path: root/src/unistd/readn.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/unistd/readn.c')
-rw-r--r--src/unistd/readn.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/src/unistd/readn.c b/src/unistd/readn.c
index b50abe5..e607f8d 100644
--- a/src/unistd/readn.c
+++ b/src/unistd/readn.c
@@ -48,7 +48,7 @@ ssize_t readn(int fd, void* buf, size_t nbyte)
int saved_errno = 0;
sigfillset(&mask);
- sigprocmask(SIG_BLOCK, &mask, &oldmask);
+ pthread_sigmask(SIG_BLOCK, &mask, &oldmask);
while (nbyte)
{
@@ -62,11 +62,11 @@ ssize_t readn(int fd, void* buf, size_t nbyte)
buffer += r;
}
- sigprocmask(SIG_SETMASK, &oldmask, NULL);
+ pthread_sigmask(SIG_SETMASK, &oldmask, NULL);
return n;
fail:
errno = saved_errno;
- sigprocmask(SIG_SETMASK, &oldmask, NULL);
+ pthread_sigmask(SIG_SETMASK, &oldmask, NULL);
saved_errno = errno;
return -1;
}