lwp: Fix stupid mistake in lock.h
[openafs.git] / src / lwp / lock.h
index 8655c85..6261348 100644 (file)
@@ -1,7 +1,7 @@
 /*
  * Copyright 2000, International Business Machines Corporation and others.
  * All Rights Reserved.
- * 
+ *
  * This software has been released under the terms of the IBM Public
  * License.  For details, see the LICENSE file in the top-level source
  * directory or online at http://www.openafs.org/dl/license10.html
 #define ENDMAC   } while (0)
 
 #ifdef AFS_PTHREAD_ENV
-#include <assert.h>
 #include <pthread.h>
-#define LOCK_LOCK(A) assert(pthread_mutex_lock(&(A)->mutex) == 0)
-#define LOCK_UNLOCK(A) assert(pthread_mutex_unlock(&(A)->mutex) == 0)
+#include <afs/opr.h>
+#define LOCK_LOCK(A) opr_Verify(pthread_mutex_lock(&(A)->mutex) == 0);
+#define LOCK_UNLOCK(A) opr_Verify(pthread_mutex_unlock(&(A)->mutex) == 0);
 #else /* AFS_PTHREAD_ENV */
 #define LOCK_LOCK(A)
 #define LOCK_UNLOCK(A)
@@ -68,6 +68,7 @@ struct Lock {
 extern void Afs_Lock_Obtain(struct Lock *lock, int how);
 extern void Afs_Lock_ReleaseR(struct Lock *lock);
 extern void Afs_Lock_ReleaseW(struct Lock *lock);
+extern void Afs_Lock_WakeupR(struct Lock *lock);
 void Lock_Init(struct Lock *lock);
 void Lock_Destroy(struct Lock *lock);