Commit 949f5e86 authored by Michael Hanselmann's avatar Michael Hanselmann
Browse files

cmdlib: Fix prototype for _QueryBase.DeclareLocks


Signed-off-by: default avatarMichael Hanselmann <hansmi@google.com>
Reviewed-by: default avatarAdeodato Simo <dato@google.com>
parent 66787da5
...@@ -533,7 +533,7 @@ class _QueryBase: ...@@ -533,7 +533,7 @@ class _QueryBase:
""" """
raise NotImplementedError() raise NotImplementedError()
def DeclareLocks(self, level): def DeclareLocks(self, lu, level):
"""Declare locks for this query. """Declare locks for this query.
See L{LogicalUnit.DeclareLocks}. See L{LogicalUnit.DeclareLocks}.
...@@ -3512,7 +3512,7 @@ class _NodeQuery(_QueryBase): ...@@ -3512,7 +3512,7 @@ class _NodeQuery(_QueryBase):
# if we don't request only static fields, we need to lock the nodes # if we don't request only static fields, we need to lock the nodes
lu.needed_locks[locking.LEVEL_NODE] = self.wanted lu.needed_locks[locking.LEVEL_NODE] = self.wanted
def DeclareLocks(self, _): def DeclareLocks(self, lu, level):
pass pass
def _GetQueryData(self, lu): def _GetQueryData(self, lu):
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment