diff options
author | Ted Unangst <tedu@cvs.openbsd.org> | 2005-12-14 04:43:05 +0000 |
---|---|---|
committer | Ted Unangst <tedu@cvs.openbsd.org> | 2005-12-14 04:43:05 +0000 |
commit | 71c346f51c5d3da24d91bd31ea19748b8c3088c9 (patch) | |
tree | cee66c541f59b04b734c073158cdca643b12ac81 /lib/librthread/rthread.h | |
parent | b8eff4de80b9474447e2d73bd0948b3ed7a4fbc4 (diff) |
add bits for pthread_cancel. we don't really have cancellation points yet
but some of the functions are here now.
Diffstat (limited to 'lib/librthread/rthread.h')
-rw-r--r-- | lib/librthread/rthread.h | 11 |
1 files changed, 7 insertions, 4 deletions
diff --git a/lib/librthread/rthread.h b/lib/librthread/rthread.h index ea5a83ae701..6eac065dbcd 100644 --- a/lib/librthread/rthread.h +++ b/lib/librthread/rthread.h @@ -1,4 +1,4 @@ -/* $OpenBSD: rthread.h,v 1.4 2005/12/14 04:01:44 tedu Exp $ */ +/* $OpenBSD: rthread.h,v 1.5 2005/12/14 04:43:04 tedu Exp $ */ /* * Copyright (c) 2004 Ted Unangst <tedu@openbsd.org> * All Rights Reserved. @@ -86,7 +86,7 @@ struct rthread_storage { struct pthread { pid_t tid; struct semaphore donesem; - int flags; + unsigned int flags; void *retval; void *(*fn)(void *); void *arg; @@ -98,8 +98,11 @@ struct pthread { struct rthread_storage *local_storage; int sigpend; }; -#define THREAD_DONE 0x001 -#define THREAD_DETACHED 0x002 +#define THREAD_DONE 0x001 +#define THREAD_DETACHED 0x002 +#define THREAD_CANCELLED 0x004 +#define THREAD_CANCEL_ENABLE 0x008 +#define THREAD_CANCEL_DEFERRED 0x010 void _spinlock(_spinlock_lock_t *); void _spinunlock(_spinlock_lock_t *); |