Revision 9a39f854

b/lib/locking.py
207 207
      elif self.__is_sharer():
208 208
        self.__shr.remove(threading.currentThread())
209 209

  
210
        # If there are shared holders waiting there *must* be an exclusive holder
211
        # waiting as well; otherwise what were they waiting for?
212
        assert self.__nwait_shr == 0 or self.__nwait_exc > 0, \
213
               "Lock sharers waiting while no exclusive is queueing"
214

  
215 210
        # If there are no more shared holders and some exclusive holders are
216 211
        # waiting let's wake one up.
217 212
        if len(self.__shr) == 0 and self.__nwait_exc > 0:

Also available in: Unified diff