Commit 340e2c74 authored by Arnaud Fontaine's avatar Arnaud Fontaine

py3: Fix global definition.

parent 704325dc
...@@ -167,6 +167,7 @@ class AlarmTool(TimerServiceMixin, BaseTool): ...@@ -167,6 +167,7 @@ class AlarmTool(TimerServiceMixin, BaseTool):
# only start when we are the alarmNode # only start when we are the alarmNode
alarmNode = self.getAlarmNode() alarmNode = self.getAlarmNode()
current_node = getCurrentNode() current_node = getCurrentNode()
global _check_upgrade
if alarmNode == '': if alarmNode == '':
self.setAlarmNode(current_node) self.setAlarmNode(current_node)
alarmNode = current_node alarmNode = current_node
...@@ -179,7 +180,6 @@ class AlarmTool(TimerServiceMixin, BaseTool): ...@@ -179,7 +180,6 @@ class AlarmTool(TimerServiceMixin, BaseTool):
elif _check_upgrade and self.getServerAddress() == alarmNode: elif _check_upgrade and self.getServerAddress() == alarmNode:
# BBB: check (once per run) if our node was alarm_node by address, and # BBB: check (once per run) if our node was alarm_node by address, and
# migrate it. # migrate it.
global _check_upgrade
_check_upgrade = False _check_upgrade = False
self.setAlarmNode(current_node) self.setAlarmNode(current_node)
finally: finally:
......
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