fix(keyringctl): avoid walking non existing paths to resolve certs
This commit is contained in:
parent
02605edee5
commit
cced93480c
@ -161,6 +161,8 @@ def get_cert_paths(paths: Iterable[Path]) -> Set[Path]:
|
|||||||
visit: List[Path] = list(paths)
|
visit: List[Path] = list(paths)
|
||||||
while visit:
|
while visit:
|
||||||
path = visit.pop()
|
path = visit.pop()
|
||||||
|
if not path.exists():
|
||||||
|
continue
|
||||||
# this level contains a certificate, abort depth search
|
# this level contains a certificate, abort depth search
|
||||||
if list(path.glob("*.asc")):
|
if list(path.glob("*.asc")):
|
||||||
cert_paths.add(path)
|
cert_paths.add(path)
|
||||||
|
Loading…
Reference in New Issue
Block a user