From 7b7d2f954251125f6c7d60ed06b3ebbee0d433e3 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Gr=C3=A9gory=20Wisniewski?= <gregory@nexedi.com>
Date: Fri, 27 Aug 2010 15:47:26 +0000
Subject: [PATCH] Use lock() provided by the transaction manager.

git-svn-id: https://svn.erp5.org/repos/neo/trunk@2239 71dcc9de-d417-0410-9af5-da40c76e7ee4
---
 neo/master/handlers/storage.py | 6 ++----
 1 file changed, 2 insertions(+), 4 deletions(-)

diff --git a/neo/master/handlers/storage.py b/neo/master/handlers/storage.py
index c0a3ba14..9c3fbc68 100644
--- a/neo/master/handlers/storage.py
+++ b/neo/master/handlers/storage.py
@@ -68,10 +68,8 @@ class StorageServiceHandler(BaseServiceHandler):
             raise ProtocolError('TID too big')
 
         # transaction locked on this storage node
-        t = tm[tid]
-        if not t.lock(uuid):
-            return
-        self._afterLock(tid)
+        if tm.lock(tid, uuid):
+            self._afterLock(tid)
 
     def _afterLock(self, tid):
         # I have received all the lock answers now:
-- 
2.30.9