aboutsummaryrefslogtreecommitdiffstats
path: root/src/unistd/pwriten.c
diff options
context:
space:
mode:
authorMattias Andrée <maandree@member.fsf.org>2015-12-29 19:14:42 +0100
committerMattias Andrée <maandree@member.fsf.org>2015-12-29 19:14:42 +0100
commit222716fdf0ed82862be02c7cae04bd226d6c6208 (patch)
tree6f053692473373dd7e0afdafecf710cee806c1a5 /src/unistd/pwriten.c
parentmore functions to add + implement readn, writen, preadn, and pwriten (diff)
downloadslibc-222716fdf0ed82862be02c7cae04bd226d6c6208.tar.gz
slibc-222716fdf0ed82862be02c7cae04bd226d6c6208.tar.bz2
slibc-222716fdf0ed82862be02c7cae04bd226d6c6208.tar.xz
use pthread_sigmask, not sigprocmask
Signed-off-by: Mattias Andrée <maandree@member.fsf.org>
Diffstat (limited to 'src/unistd/pwriten.c')
-rw-r--r--src/unistd/pwriten.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/src/unistd/pwriten.c b/src/unistd/pwriten.c
index fefe537..91deb37 100644
--- a/src/unistd/pwriten.c
+++ b/src/unistd/pwriten.c
@@ -49,7 +49,7 @@ ssize_t pwriten(int fd, const void* buf, size_t nbyte, off_t offset)
int saved_errno = 0;
sigfillset(&mask);
- sigprocmask(SIG_BLOCK, &mask, &oldmask);
+ pthread_sigmask(SIG_BLOCK, &mask, &oldmask);
while (nbyte)
{
@@ -64,11 +64,11 @@ ssize_t pwriten(int fd, const void* buf, size_t nbyte, off_t offset)
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;
}