From 2bddf79a3d4bbde30882dc607ff80d497a57eb52 Mon Sep 17 00:00:00 2001 From: Ben Kurtovic Date: Mon, 18 Aug 2014 15:51:00 -0400 Subject: [PATCH] Fix deadlock when calling queue.put() while holding the mutex. --- earwigbot/wiki/copyvios/__init__.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/earwigbot/wiki/copyvios/__init__.py b/earwigbot/wiki/copyvios/__init__.py index a1a709f..b33587c 100644 --- a/earwigbot/wiki/copyvios/__init__.py +++ b/earwigbot/wiki/copyvios/__init__.py @@ -73,7 +73,7 @@ class _CopyvioWorkspace(object): for worker in self._workers.itervalues(): with worker.queue.mutex: worker.queue.queue.clear() - worker.queue.put(None) + worker.queue.queue.append(None) self._is_finished = True def enqueue(self, urls, exclude_check=None):