Commit cee365b4 authored by Michal 'vorner' Vaner's avatar Michal 'vorner' Vaner
Browse files

[2676] Remove unused variable

parent f5ba7aa6
......@@ -77,8 +77,8 @@ class MyZonemgrRefresh(ZonemgrRefresh):
return None
sqlite3_ds.get_zone_soa = get_zone_soa
ZonemgrRefresh.__init__(self, None, TEST_SQLITE3_DBFILE,
self._slave_socket, FakeCCSession())
ZonemgrRefresh.__init__(self, TEST_SQLITE3_DBFILE, self._slave_socket,
FakeCCSession())
current_time = time.time()
self._zonemgr_refresh_info = {
('example.net.', 'IN'): {
......@@ -656,8 +656,8 @@ class TestZonemgr(unittest.TestCase):
self.zonemgr.config_handler(config_data3)
self.assertEqual(0.5, self.zonemgr._config_data.get("refresh_jitter"))
# The zone doesn't exist in database, simply skip loading soa for it and log an warning
self.zonemgr._zone_refresh = ZonemgrRefresh(None, TEST_SQLITE3_DBFILE,
None, FakeCCSession())
self.zonemgr._zone_refresh = ZonemgrRefresh(TEST_SQLITE3_DBFILE, None,
FakeCCSession())
config_data1["secondary_zones"] = [{"name": "nonexistent.example",
"class": "IN"}]
self.assertEqual(self.zonemgr.config_handler(config_data1),
......
......@@ -103,8 +103,7 @@ class ZonemgrRefresh:
can be stopped by calling shutdown() in another thread.
"""
def __init__(self, cc, db_file, slave_socket, module_cc_session):
self._cc = cc
def __init__(self, db_file, slave_socket, module_cc_session):
self._mccs = module_cc_session
self._check_sock = slave_socket
self._db_file = db_file
......@@ -523,7 +522,7 @@ class Zonemgr:
self._db_file = self.get_db_file()
# Create socket pair for communicating between main thread and zonemgr timer thread
self._master_socket, self._slave_socket = socket.socketpair(socket.AF_UNIX, socket.SOCK_STREAM)
self._zone_refresh = ZonemgrRefresh(self._cc, self._db_file, self._slave_socket, self._module_cc)
self._zone_refresh = ZonemgrRefresh(self._db_file, self._slave_socket, self._module_cc)
self._zone_refresh.run_timer()
self._lock = threading.Lock()
......@@ -534,7 +533,6 @@ class Zonemgr:
"""Setup two sessions for zonemgr, one(self._module_cc) is used for receiving
commands and config data sent from other modules, another one (self._cc)
is used to send commands to proper modules."""
self._cc = isc.cc.Session()
self._module_cc = isc.config.ModuleCCSession(SPECFILE_LOCATION,
self.config_handler,
self.command_handler)
......
Supports Markdown
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