summaryrefslogtreecommitdiff
path: root/python/helpers/pydev/_pydev_imps/_pydev_Queue.py
diff options
context:
space:
mode:
authorTor Norbye <tnorbye@google.com>2014-09-04 20:44:00 +0000
committerGerrit Code Review <noreply-gerritcodereview@google.com>2014-09-04 20:44:01 +0000
commitfb5a02906f644d044eb0286bf27d413ba0e05216 (patch)
treebca7d49005d81d10c70bc3f547df041c636b4300 /python/helpers/pydev/_pydev_imps/_pydev_Queue.py
parent9cde0e3c015174898df8b8f3672185941fad4786 (diff)
parentd245f58efbfc26b13b9b9d5e52e6a83a0d76216c (diff)
downloadidea-fb5a02906f644d044eb0286bf27d413ba0e05216.tar.gz
Merge "Merge remote-tracking branch 'aosp/upstream-master' into merge"
Diffstat (limited to 'python/helpers/pydev/_pydev_imps/_pydev_Queue.py')
-rw-r--r--python/helpers/pydev/_pydev_imps/_pydev_Queue.py3
1 files changed, 2 insertions, 1 deletions
diff --git a/python/helpers/pydev/_pydev_imps/_pydev_Queue.py b/python/helpers/pydev/_pydev_imps/_pydev_Queue.py
index d351b505a3e0..52e83b0de290 100644
--- a/python/helpers/pydev/_pydev_imps/_pydev_Queue.py
+++ b/python/helpers/pydev/_pydev_imps/_pydev_Queue.py
@@ -1,6 +1,7 @@
"""A multi-producer, multi-consumer queue."""
from _pydev_imps._pydev_time import time as _time
+from _pydev_imps import _pydev_thread
try:
import _pydev_threading as _threading
except ImportError:
@@ -30,7 +31,7 @@ class Queue:
# that acquire mutex must release it before returning. mutex
# is shared between the three conditions, so acquiring and
# releasing the conditions also acquires and releases mutex.
- self.mutex = _threading.Lock()
+ self.mutex = _pydev_thread.allocate_lock()
# Notify not_empty whenever an item is added to the queue; a
# thread waiting to get is notified then.
self.not_empty = _threading.Condition(self.mutex)