Commit 2fa4cc55 authored by Georg Brandl's avatar Georg Brandl

Support new Condition return value in the multiprocessing version.

parent 7362c4f3
......@@ -217,7 +217,7 @@ class Condition(object):
try:
# wait for notification or timeout
self._wait_semaphore.acquire(True, timeout)
ret = self._wait_semaphore.acquire(True, timeout)
finally:
# indicate that this thread has woken
self._woken_count.release()
......@@ -225,6 +225,7 @@ class Condition(object):
# reacquire lock
for i in range(count):
self._lock.acquire()
return ret
def notify(self):
assert self._lock._semlock._is_mine(), 'lock is not owned'
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment