diff options
author | Ulrich Drepper <drepper@redhat.com> | 2000-09-05 08:32:03 +0000 |
---|---|---|
committer | Ulrich Drepper <drepper@redhat.com> | 2000-09-05 08:32:03 +0000 |
commit | 7f667ba20c54bf56ccbb76c4b1d85628297ffbef (patch) | |
tree | 2df9c76ec3691d602157ee6297b516a9d0d26a75 /linuxthreads | |
parent | d3d726ab8fcb54f5fd23fea03e42e150621c1268 (diff) | |
download | glibc-7f667ba20c54bf56ccbb76c4b1d85628297ffbef.tar.gz glibc-7f667ba20c54bf56ccbb76c4b1d85628297ffbef.tar.xz glibc-7f667ba20c54bf56ccbb76c4b1d85628297ffbef.zip |
(__pthread_mutex_unlock): Correct test for already unlocked mutex.
Diffstat (limited to 'linuxthreads')
-rw-r--r-- | linuxthreads/mutex.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/linuxthreads/mutex.c b/linuxthreads/mutex.c index ae070e5b93..9ce4a30820 100644 --- a/linuxthreads/mutex.c +++ b/linuxthreads/mutex.c @@ -171,7 +171,7 @@ int __pthread_mutex_unlock(pthread_mutex_t * mutex) __pthread_unlock(&mutex->__m_lock); return 0; case PTHREAD_MUTEX_ERRORCHECK_NP: - if (mutex->__m_owner != thread_self() || (mutex->__m_lock.__status & 1) == 0) + if (mutex->__m_owner != thread_self() || mutex->__m_lock.__status == 0) return EPERM; mutex->__m_owner = NULL; __pthread_alt_unlock(&mutex->__m_lock); |