summaryrefslogtreecommitdiff
path: root/lib/libpthread/thread/thr_sigpending.c
diff options
context:
space:
mode:
authorDaniel Eischen <deischen@FreeBSD.org>2001-01-24 13:03:38 +0000
committerDaniel Eischen <deischen@FreeBSD.org>2001-01-24 13:03:38 +0000
commite5106342c6de9cbe26c4827e4e29bae309cd8cfb (patch)
tree5199387f09deaa21f12482317c165f815c4e8c2b /lib/libpthread/thread/thr_sigpending.c
parentf9447cd11209a5fb5ecef3f4cbe539e990f3b1bd (diff)
Notes
Diffstat (limited to 'lib/libpthread/thread/thr_sigpending.c')
-rw-r--r--lib/libpthread/thread/thr_sigpending.c9
1 files changed, 4 insertions, 5 deletions
diff --git a/lib/libpthread/thread/thr_sigpending.c b/lib/libpthread/thread/thr_sigpending.c
index a118347ca974..98b7d268d0c8 100644
--- a/lib/libpthread/thread/thr_sigpending.c
+++ b/lib/libpthread/thread/thr_sigpending.c
@@ -33,13 +33,15 @@
*/
#include <signal.h>
#include <errno.h>
-#ifdef _THREAD_SAFE
#include <pthread.h>
#include "pthread_private.h"
+#pragma weak sigpending=_sigpending
+
int
_sigpending(sigset_t * set)
{
+ struct pthread *curthread = _get_curthread();
int ret = 0;
/* Check for a null signal set pointer: */
@@ -48,11 +50,8 @@ _sigpending(sigset_t * set)
ret = EINVAL;
}
else {
- *set = _thread_run->sigpend;
+ *set = curthread->sigpend;
}
/* Return the completion status: */
return (ret);
}
-
-__strong_reference(_sigpending, sigpending);
-#endif