mirror of
https://github.com/evilsocket/opensnitch.git
synced 2025-03-04 08:34:40 +01:00
ui: minor improvements
- delete ipc socket on exit - save ipc socket under /run/user/.../opensnitch/ - added new contributor
This commit is contained in:
parent
81d7333c2b
commit
9259442451
2 changed files with 8 additions and 2 deletions
|
@ -3,6 +3,7 @@
|
|||
# Copyright (C) 2018 Simone Margaritelli
|
||||
# 2018 MiWCryptAnalytics
|
||||
# 2023 munix9
|
||||
# 2023 Wojtek Widomski
|
||||
# 2019-2023 Gustavo Iñiguez Goia
|
||||
#
|
||||
# This file is part of OpenSnitch.
|
||||
|
@ -51,6 +52,10 @@ app_id = os.path.join(xdg_opensnitch_dir, "io.github.evilsocket.opensnitch")
|
|||
def on_exit():
|
||||
server.stop(0)
|
||||
app.quit()
|
||||
try:
|
||||
os.remove(app_id)
|
||||
except:
|
||||
pass
|
||||
sys.exit(0)
|
||||
|
||||
def supported_qt_version(major, medium, minor):
|
||||
|
|
|
@ -2,6 +2,7 @@
|
|||
import os
|
||||
import re
|
||||
import shutil
|
||||
import stat
|
||||
|
||||
# https://github.com/takluyver/pyxdg/blob/1d23e483ae869ee9532aca43b133cc43f63626a3/xdg/BaseDirectory.py
|
||||
def get_runtime_dir(strict=True):
|
||||
|
@ -44,9 +45,9 @@ def get_runtime_dir(strict=True):
|
|||
def get_run_opensnitch_dir():
|
||||
rdir = get_runtime_dir(False)
|
||||
if 'opensnitch' not in rdir:
|
||||
odir = os.path.join(rdir, 'opensnitch')
|
||||
rdir = os.path.join(rdir, 'opensnitch')
|
||||
try:
|
||||
os.makedirs(odir, 0o700)
|
||||
os.makedirs(rdir, 0o700)
|
||||
except:
|
||||
pass
|
||||
|
||||
|
|
Loading…
Add table
Reference in a new issue