diff options
author | Kali Kaneko <kali@leap.se> | 2018-01-18 15:37:18 +0100 |
---|---|---|
committer | Kali Kaneko <kali@leap.se> | 2018-01-25 01:19:16 +0100 |
commit | c3306592fbb54fab0da44a8faaa8a1c6954537fd (patch) | |
tree | 0a9b406f81d33af40e1e943f0e330c28b06eb9ed /src/leap/bitmask/vpn/autostart.py | |
parent | 276c717b0d1d662cabc117cea7373418efedde09 (diff) |
[feat] report missing polkit properly from main UI
also refactor and move polkit_agent so that it does not depend on having
bitmask on the path.
Diffstat (limited to 'src/leap/bitmask/vpn/autostart.py')
-rw-r--r-- | src/leap/bitmask/vpn/autostart.py | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/src/leap/bitmask/vpn/autostart.py b/src/leap/bitmask/vpn/autostart.py index 43abfdf5..af7b3669 100644 --- a/src/leap/bitmask/vpn/autostart.py +++ b/src/leap/bitmask/vpn/autostart.py @@ -34,7 +34,10 @@ Terminal=false with open(autostart_file, 'w') as f: f.write(AUTOSTART) elif status == 'off': - os.unlink(autostart_file) + try: + os.unlink(autostart_file) + except OSError: + pass if IS_MAC: |