summaryrefslogtreecommitdiff
path: root/src/leap/base
diff options
context:
space:
mode:
authorantialias <antialias@leap.se>2012-10-01 15:10:55 -0400
committerantialias <antialias@leap.se>2012-10-01 15:10:55 -0400
commit95ce59c8833cb2ba951630080cdbc1e6d756a666 (patch)
tree8434a07650ef78497daff7e2f9f100a500adf9b4 /src/leap/base
parentc75b27484a999f70a6e28e521f236cf2d403edd1 (diff)
Still some QT related problems. Hand off to kali to fix.
Diffstat (limited to 'src/leap/base')
-rw-r--r--src/leap/base/network.py8
1 files changed, 3 insertions, 5 deletions
diff --git a/src/leap/base/network.py b/src/leap/base/network.py
index 92fb7635..159e9b21 100644
--- a/src/leap/base/network.py
+++ b/src/leap/base/network.py
@@ -21,15 +21,15 @@ class NetworkChecker(object):
def __init__(self, *args, **kwargs):
self.status_signals = kwargs.pop('status_signals', None)
self.watcher_cb = kwargs.pop('status_signals', None)
- self.excp_logger = lambda exc: logger.error("%s", exc.message)
+ self.error_cb = kwargs.pop('error_cb',
+ lambda exc: logger.error("%s", exc.message))
self.shutdown = threading.Event()
self.checker = LeapNetworkChecker()
def start(self):
- self.process_handle = self._launch_recurrent_network_checks((self.excp_logger,))
+ self.process_handle = self._launch_recurrent_network_checks((self.error_cb,))
def stop(self):
- #TODO: Thread still not being stopped when openvpn is stopped.
self.shutdown.set()
logger.debug("network checked stopped.")
@@ -70,5 +70,3 @@ class NetworkChecker(object):
self._network_checks_thread,
(fail_callbacks,))
return watcher
-
-