Author: rrelyea
Update of /cvs/dirsec/coolkey/src/coolkey
In directory cvs-int.fedora.redhat.com:/tmp/cvs-serv14747/src/coolkey
Modified Files:
machdep.cpp
Log Message:
fix pthread issue.
Index: machdep.cpp
===================================================================
RCS file: /cvs/dirsec/coolkey/src/coolkey/machdep.cpp,v
retrieving revision 1.1
retrieving revision 1.2
diff -u -r1.1 -r1.2
--- machdep.cpp 9 Jun 2006 18:39:11 -0000 1.1
+++ machdep.cpp 13 Jul 2006 21:32:39 -0000 1.2
@@ -328,7 +328,7 @@
pthread_mutex_t mutex;
};
-static pthread_mutexattr_t OSLock_attr;
+static pthread_mutexattr_t OSLock_attr = {0};
static int OSLock_attr_init = 0;
OSLock::OSLock(bool exceptionAllowed)
@@ -336,6 +336,7 @@
int rc;
lockData = NULL;
+#ifdef MAC
if (!OSLock_attr_init) {
rc = pthread_mutexattr_init(&OSLock_attr);
if (rc < 0) {
@@ -347,6 +348,7 @@
}
OSLock_attr_init = 1;
}
+#endif
lockData = new OSLockData;
if (lockData) {
rc = pthread_mutex_init(&lockData->mutex, &OSLock_attr);
Show replies by thread