summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJoshua Harlow <harlowja@gmail.com>2014-08-31 00:15:06 -0700
committerJoshua Harlow <harlowja@gmail.com>2014-08-31 00:15:06 -0700
commitf42c162e3ba8f15c1b51e77c2fa62e20a8ac176f (patch)
tree59d7d64ddf1e79cc482b0dd35be19d5c2ecf652a
parente6fc8c16e67ed9f88fa3bec130edf249fa8b6160 (diff)
downloadzake-f42c162e3ba8f15c1b51e77c2fa62e20a8ac176f.tar.gz
After further reading locks seem needed around mutating operations
-rw-r--r--zake/fake_storage.py3
1 files changed, 2 insertions, 1 deletions
diff --git a/zake/fake_storage.py b/zake/fake_storage.py
index 8b6f774..4d89cf6 100644
--- a/zake/fake_storage.py
+++ b/zake/fake_storage.py
@@ -237,7 +237,8 @@ class FakeStorage(object):
if path == ROOT_PATH:
raise k_exceptions.BadArgumentsError("Can not delete %s"
% ROOT_PATH)
- self._paths.pop(path)
+ with self.lock:
+ self._paths.pop(path)
def get(self, path):
with self.lock: