mirror of https://github.com/borgbase/vorta
Fix crash due to zombie processes (#174)
This commit is contained in:
parent
eb50885371
commit
beb3dc8909
|
@ -266,7 +266,12 @@ def format_archive_name(profile, archive_name_tpl):
|
||||||
def get_mount_points(repo_url):
|
def get_mount_points(repo_url):
|
||||||
mount_points = {}
|
mount_points = {}
|
||||||
for proc in psutil.process_iter():
|
for proc in psutil.process_iter():
|
||||||
if proc.name() == 'borg' or proc.name().startswith('python'):
|
try:
|
||||||
|
name = proc.name()
|
||||||
|
except Exception:
|
||||||
|
# Getting the process name may fail (e.g. zombie process on macOS)
|
||||||
|
continue
|
||||||
|
if name == 'borg' or name.startswith('python'):
|
||||||
if 'mount' not in proc.cmdline():
|
if 'mount' not in proc.cmdline():
|
||||||
continue
|
continue
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue