Change in vdsm[master]: clusterLock: Make inquire retval consistent

alitke at redhat.com alitke at redhat.com
Tue Mar 10 17:12:02 UTC 2015


Adam Litke has uploaded a new change for review.

Change subject: clusterLock: Make inquire retval consistent
......................................................................

clusterLock: Make inquire retval consistent

Callers of clusterLock.inquire() expect a tuple with two values to be
returned.  The SANLock flavor gets this right but LocalLock returns a
single None when the lock has no owners.  It should return None, None.

Change-Id: Id4b9227773e44d48b21aa4eaba7c7fe1ab599931
Signed-off-by: Adam Litke <alitke at redhat.com>
---
M vdsm/storage/clusterlock.py
1 file changed, 1 insertion(+), 1 deletion(-)


  git pull ssh://gerrit.ovirt.org:29418/vdsm refs/changes/52/38552/1

diff --git a/vdsm/storage/clusterlock.py b/vdsm/storage/clusterlock.py
index 24a5d81..51d2906 100644
--- a/vdsm/storage/clusterlock.py
+++ b/vdsm/storage/clusterlock.py
@@ -465,7 +465,7 @@
     def inquire(self):
         with self._globalLockMapSync:
             hostId, lockFile = self._getLease()
-            return self.LVER, hostId if lockFile else None
+            return self.LVER, hostId if lockFile else None, None
 
     def release(self):
         with self._globalLockMapSync:


-- 
To view, visit https://gerrit.ovirt.org/38552
To unsubscribe, visit https://gerrit.ovirt.org/settings

Gerrit-MessageType: newchange
Gerrit-Change-Id: Id4b9227773e44d48b21aa4eaba7c7fe1ab599931
Gerrit-PatchSet: 1
Gerrit-Project: vdsm
Gerrit-Branch: master
Gerrit-Owner: Adam Litke <alitke at redhat.com>


More information about the vdsm-patches mailing list