diff options
author | Ulrich Drepper <drepper@redhat.com> | 2000-01-17 04:00:04 +0000 |
---|---|---|
committer | Ulrich Drepper <drepper@redhat.com> | 2000-01-17 04:00:04 +0000 |
commit | 2449110a8ae9b7fb65259560a96b6fafd14e791f (patch) | |
tree | 94f74bb950c566fa4438d23bd60f27c59a6d730b /linuxthreads | |
parent | 01ff9d0b5496c8bc5c7c1295485c05d52bbdfa9c (diff) | |
download | glibc-2449110a8ae9b7fb65259560a96b6fafd14e791f.zip glibc-2449110a8ae9b7fb65259560a96b6fafd14e791f.tar.gz glibc-2449110a8ae9b7fb65259560a96b6fafd14e791f.tar.bz2 |
Update.
* Makeconfig (rpath-dirs): Remove db2.
(dbojdir): Remove variable.
Diffstat (limited to 'linuxthreads')
-rw-r--r-- | linuxthreads/ChangeLog | 8 | ||||
-rw-r--r-- | linuxthreads/rwlock.c | 6 |
2 files changed, 12 insertions, 2 deletions
diff --git a/linuxthreads/ChangeLog b/linuxthreads/ChangeLog index c783b3b..754534e 100644 --- a/linuxthreads/ChangeLog +++ b/linuxthreads/ChangeLog @@ -1,3 +1,11 @@ +2000-01-16 Ulrich Drepper <drepper@cygnus.com> + + * rwlock.c (pthread_rwlock_unlock): Correct one more problem with + preference handling. + (pthread_rwlockattr_setkind_np): Allow + PTHREAD_RWLOCK_PREFER_WRITER_NONRECURSIVE_NP. + Patches by Kaz Kylheku <kaz@ashi.footprints.net>. + 2000-01-12 Ulrich Drepper <drepper@cygnus.com> * internals.h (pthread_readlock_info): New structure. diff --git a/linuxthreads/rwlock.c b/linuxthreads/rwlock.c index 7b472e2..e1401c3 100644 --- a/linuxthreads/rwlock.c +++ b/linuxthreads/rwlock.c @@ -362,8 +362,9 @@ pthread_rwlock_unlock (pthread_rwlock_t *rwlock) } rwlock->__rw_writer = NULL; - if (rwlock->__rw_kind == PTHREAD_RWLOCK_PREFER_READER_NP - || (th = dequeue (&rwlock->__rw_write_waiting)) == NULL) + if ((rwlock->__rw_kind == PTHREAD_RWLOCK_PREFER_READER_NP + && !queue_is_empty(&rwlock->__rw_read_waiting)) + || (th = dequeue(&rwlock->__rw_write_waiting)) == NULL) { /* Restart all waiting readers. */ torestart = rwlock->__rw_read_waiting; @@ -477,6 +478,7 @@ pthread_rwlockattr_setkind_np (pthread_rwlockattr_t *attr, int pref) { if (pref != PTHREAD_RWLOCK_PREFER_READER_NP && pref != PTHREAD_RWLOCK_PREFER_WRITER_NP + && pref != PTHREAD_RWLOCK_PREFER_WRITER_NONRECURSIVE_NP && pref != PTHREAD_RWLOCK_DEFAULT_NP) return EINVAL; |