* ATOMIC-DECF doesn't do any good if the other write isn't atomic as
well: even though we are always holding the lock while incrementing
the waitcount, the possibly unlocked but atomic decrement means the
increment needs to be atomic too.
(setf (semaphore-%count semaphore) (1- count))
(unwind-protect
(progn
- (incf (semaphore-waitcount semaphore))
+ ;; Need to use ATOMIC-INCF despite the lock, because on our
+ ;; way out from here we might not be locked anymore -- so
+ ;; another thread might be tweaking this in parallel using
+ ;; ATOMIC-DECF.
+ (atomic-incf (semaphore-waitcount semaphore))
(loop until (plusp (setf count (semaphore-%count semaphore)))
do (condition-wait (semaphore-queue semaphore)
(semaphore-mutex semaphore)))
;;; checkins which aren't released. (And occasionally for internal
;;; versions, especially for internal versions off the main CVS
;;; branch, it gets hairier, e.g. "0.pre7.14.flaky4.13".)
-"1.0.37.13"
+"1.0.37.14"