summaryrefslogtreecommitdiff
path: root/src/leap/bitmask/vpn/service.py
diff options
context:
space:
mode:
Diffstat (limited to 'src/leap/bitmask/vpn/service.py')
-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):