diff options
author | Georg Brandl <georg@python.org> | 2010-10-28 13:01:06 (GMT) |
---|---|---|
committer | Georg Brandl <georg@python.org> | 2010-10-28 13:01:06 (GMT) |
commit | 2fa4cc55e9e5fdf1817d5ff1d82a23eb12b69e40 (patch) | |
tree | e5aa601ebe31485f9538ee9a4ed35581d4e2e694 /Lib/multiprocessing/synchronize.py | |
parent | 7362c4f3111424e35c47c13164f982d663abfd86 (diff) | |
download | cpython-2fa4cc55e9e5fdf1817d5ff1d82a23eb12b69e40.zip cpython-2fa4cc55e9e5fdf1817d5ff1d82a23eb12b69e40.tar.gz cpython-2fa4cc55e9e5fdf1817d5ff1d82a23eb12b69e40.tar.bz2 |
Support new Condition return value in the multiprocessing version.
Diffstat (limited to 'Lib/multiprocessing/synchronize.py')
-rw-r--r-- | Lib/multiprocessing/synchronize.py | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/Lib/multiprocessing/synchronize.py b/Lib/multiprocessing/synchronize.py index 7f4718c..edf6c3e 100644 --- a/Lib/multiprocessing/synchronize.py +++ b/Lib/multiprocessing/synchronize.py @@ -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' |