From cb75275827e762a716a15459bb540a423f1fed3c Mon Sep 17 00:00:00 2001 From: Lokesh Mandvekar Date: Wed, 8 Jul 2015 12:04:17 -0500 Subject: [PATCH] remove lock atomic doesn't work on rhel without this :( Signed-off-by: Lokesh Mandvekar --- docker/unixconn/unixconn.py | 17 ++++++++--------- 1 file changed, 8 insertions(+), 9 deletions(-) diff --git a/docker/unixconn/unixconn.py b/docker/unixconn/unixconn.py index 551bd29..4c4c8e5 100644 --- a/docker/unixconn/unixconn.py +++ b/docker/unixconn/unixconn.py @@ -68,15 +68,14 @@ class UnixAdapter(requests.adapters.HTTPAdapter): super(UnixAdapter, self).__init__() def get_connection(self, url, proxies=None): - with self.pools.lock: - pool = self.pools.get(url) - if pool: - return pool - - pool = UnixHTTPConnectionPool(url, - self.socket_path, - self.timeout) - self.pools[url] = pool + pool = self.pools.get(url) + if pool: + return pool + + pool = UnixHTTPConnectionPool(url, + self.socket_path, + self.timeout) + self.pools[url] = pool return pool -- 2.4.5