From 8153e7e3535cbdc6f5754fc8abe8ab67c7bd71fd Mon Sep 17 00:00:00 2001
From: Iustin Pop <iustin@google.com>
Date: Sun, 14 Dec 2008 12:03:03 +0000
Subject: [PATCH] cleanup: LUAddNode, LUSetNodeParams unused variable

This is a leftover from the abstraction of AdjustCandidatePool, and it
also requires the config lock, so it's better to remove it.

Reviewed-by: amishchenko
---
 lib/cmdlib.py | 2 --
 1 file changed, 2 deletions(-)

diff --git a/lib/cmdlib.py b/lib/cmdlib.py
index 6a9d2a31e..7d9b50571 100644
--- a/lib/cmdlib.py
+++ b/lib/cmdlib.py
@@ -2011,7 +2011,6 @@ class LUAddNode(LogicalUnit):
                                    " based ping to noded port")
 
     cp_size = self.cfg.GetClusterInfo().candidate_pool_size
-    node_info = self.cfg.GetAllNodesInfo().values()
     mc_now, _ = self.cfg.GetMasterCandidateStats()
     master_candidate = mc_now < cp_size
 
@@ -2178,7 +2177,6 @@ class LUSetNodeParams(LogicalUnit):
         raise errors.OpPrereqError("The master node has to be a"
                                    " master candidate and online")
       cp_size = self.cfg.GetClusterInfo().candidate_pool_size
-      node_info = self.cfg.GetAllNodesInfo().values()
       num_candidates, _ = self.cfg.GetMasterCandidateStats()
       if num_candidates <= cp_size:
         msg = ("Not enough master candidates (desired"
-- 
GitLab