summaryrefslogtreecommitdiff
path: root/lib/libc_r/uthread/uthread_sigwait.c
diff options
context:
space:
mode:
authorDavid Leonard <d@cvs.openbsd.org>1999-01-17 23:57:29 +0000
committerDavid Leonard <d@cvs.openbsd.org>1999-01-17 23:57:29 +0000
commit5ca1f71120ac2bc81b65a6cef298606b92242903 (patch)
tree82d901bf8097936d39c68cdb89cc598d1e1fccd6 /lib/libc_r/uthread/uthread_sigwait.c
parent209640f64878cc32de9cf45178c9a0e979525bdd (diff)
pthread_cancel() and cancellation points
Diffstat (limited to 'lib/libc_r/uthread/uthread_sigwait.c')
-rw-r--r--lib/libc_r/uthread/uthread_sigwait.c6
1 files changed, 5 insertions, 1 deletions
diff --git a/lib/libc_r/uthread/uthread_sigwait.c b/lib/libc_r/uthread/uthread_sigwait.c
index 8432e879646..3593b72853f 100644
--- a/lib/libc_r/uthread/uthread_sigwait.c
+++ b/lib/libc_r/uthread/uthread_sigwait.c
@@ -29,7 +29,7 @@
* OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
* SUCH DAMAGE.
*
- * $OpenBSD: uthread_sigwait.c,v 1.3 1999/01/06 05:29:28 d Exp $
+ * $OpenBSD: uthread_sigwait.c,v 1.4 1999/01/17 23:57:27 d Exp $
*/
#include <signal.h>
#include <errno.h>
@@ -45,6 +45,7 @@ sigwait(const sigset_t * set, int *sig)
sigset_t tempset;
struct sigaction act;
+ _thread_enter_cancellation_point();
/*
* Specify the thread kernel signal handler.
*/
@@ -75,6 +76,7 @@ sigwait(const sigset_t * set, int *sig)
/* Return the signal number to the caller: */
*sig = i;
+ _thread_leave_cancellation_point();
return (0);
}
@@ -127,6 +129,8 @@ sigwait(const sigset_t * set, int *sig)
}
}
+ _thread_leave_cancellation_point();
+
/* Return the completion status: */
return (ret);
}