mirror of
https://github.com/mofeng-git/One-KVM.git
synced 2025-12-12 01:00:29 +08:00
silence the systemd/dbus exception if there are no matching services (#182)
This commit is contained in:
parent
cc66fbf1df
commit
5045d8b3d7
@ -75,6 +75,10 @@ class SystemdUnitInfo:
|
||||
async def close(self) -> None:
|
||||
try:
|
||||
if self.__bus is not None:
|
||||
try:
|
||||
await self.__manager.call_get_default_target()
|
||||
except:
|
||||
pass
|
||||
self.__bus.disconnect()
|
||||
await self.__bus.wait_for_disconnect()
|
||||
except Exception:
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user