summaryrefslogtreecommitdiffstats
path: root/winsup/cygwin/thread.h
diff options
context:
space:
mode:
authorThomas Pfaff <tpfaff@gmx.net>2003-01-09 20:50:23 +0000
committerThomas Pfaff <tpfaff@gmx.net>2003-01-09 20:50:23 +0000
commit5d68d1de45400056dceb95f4329669148a536a84 (patch)
tree5a902616b858b308f58c24a0d4fce1ddebc3e54f /winsup/cygwin/thread.h
parenta54470c7742197c22a37d0429cd135f2ee7abeb8 (diff)
downloadcygnal-5d68d1de45400056dceb95f4329669148a536a84.tar.gz
cygnal-5d68d1de45400056dceb95f4329669148a536a84.tar.bz2
cygnal-5d68d1de45400056dceb95f4329669148a536a84.zip
Applied pthread_mutex patch
Diffstat (limited to 'winsup/cygwin/thread.h')
-rw-r--r--winsup/cygwin/thread.h10
1 files changed, 9 insertions, 1 deletions
diff --git a/winsup/cygwin/thread.h b/winsup/cygwin/thread.h
index a4a4f1504..cf08a7630 100644
--- a/winsup/cygwin/thread.h
+++ b/winsup/cygwin/thread.h
@@ -162,6 +162,8 @@ private:
#define SEM_MAGIC PTHREAD_MAGIC+7
#define PTHREAD_ONCE_MAGIC PTHREAD_MAGIC+8;
+#define MUTEX_LOCK_COUNTER_INITIAL (-1)
+
/* verifyable_object should not be defined here - it's a general purpose class */
class verifyable_object
@@ -305,15 +307,21 @@ public:
static void initMutex ();
static int init (pthread_mutex_t *, const pthread_mutexattr_t *);
- CRITICAL_SECTION criticalsection;
+ LONG lock_counter;
HANDLE win32_obj_id;
+ unsigned int recursion_counter;
LONG condwaits;
+ pthread_t owner;
+ int type;
int pshared;
class pthread_mutex * next;
int Lock ();
int TryLock ();
int UnLock ();
+ int Destroy ();
+ void SetOwner ();
+ int LockRecursive ();
void fixup_after_fork ();
pthread_mutex (pthread_mutexattr * = NULL);