From: Simon Wilkinson Date: Fri, 7 Sep 2012 10:43:21 +0000 (+0100) Subject: lwp: Fix stupid mistake in lock.h X-Git-Tag: upstream/1.8.0_pre1^2~2033 X-Git-Url: https://git.michaelhowe.org/gitweb/?a=commitdiff_plain;h=61d417c1a3770f2a53ef883f9ec2ed077184ab1d;p=packages%2Fo%2Fopenafs.git lwp: Fix stupid mistake in lock.h My earlier change to lock.h got the sense of the opr_Verify test wrong, so we would assert() whenever the lock call succeeded. Fix this, so things work again. Change-Id: I7e2fda473343c7b541d6ca120ef0977adcf35f62 Reviewed-on: http://gerrit.openafs.org/8053 Reviewed-by: Derrick Brashear Tested-by: Derrick Brashear --- diff --git a/src/lwp/lock.h b/src/lwp/lock.h index 051eabedf..626134890 100644 --- a/src/lwp/lock.h +++ b/src/lwp/lock.h @@ -45,8 +45,8 @@ #ifdef AFS_PTHREAD_ENV #include #include -#define LOCK_LOCK(A) opr_Verify(pthread_mutex_lock(&(A)->mutex)); -#define LOCK_UNLOCK(A) opr_Verify(pthread_mutex_unlock(&(A)->mutex)); +#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)