summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorKali Kaneko <kali@leap.se>2018-02-13 22:40:50 +0100
committerKali Kaneko <kali@leap.se>2018-02-15 16:36:48 +0100
commit109dcbe31064c3f6ba96309c39277638bfc82b9e (patch)
tree6b189cb4be315eafa0bc117a2f9ed21edec7de83 /src
parentde30dbb6b6ad337da0ad82cef16d7cdff67fd05d (diff)
[bug] do not attempt to stop a non running looping call
Diffstat (limited to 'src')
-rw-r--r--src/leap/bitmask/vpn/service.py3
1 files changed, 2 insertions, 1 deletions
diff --git a/src/leap/bitmask/vpn/service.py b/src/leap/bitmask/vpn/service.py
index 9faedd95..afa75e5e 100644
--- a/src/leap/bitmask/vpn/service.py
+++ b/src/leap/bitmask/vpn/service.py
@@ -179,7 +179,8 @@ class VPNService(HookableService):
if not vpn_ok:
raise Exception('Error stopping VPN')
- self.watchdog.stop()
+ if self.watchdog.running:
+ self.watchdog.stop()
return {'result': 'vpn stopped'}
def _set_autostart(self, status):