kete: ignore dbus errors during StopSearch
we may call StopSearch after the daemon vanished and while we're stopping all the workers. Ignore the ServiceUnknown error here.
This commit is contained in:
parent
ddef5ea38a
commit
b305d6e287
|
@ -302,7 +302,13 @@ class TuhiKeteManager(_DBusObject):
|
|||
self.proxy.StartSearch()
|
||||
|
||||
def stop_search(self):
|
||||
self.proxy.StopSearch()
|
||||
try:
|
||||
self.proxy.StopSearch()
|
||||
except GLib.Error as e:
|
||||
if (e.domain != 'g-dbus-error-quark' or
|
||||
e.code != Gio.IOErrorEnum.EXISTS or
|
||||
Gio.dbus_error_get_remote_error(e) != 'org.freedesktop.DBus.Error.ServiceUnknown'):
|
||||
raise e
|
||||
self._pairable_devices = {}
|
||||
|
||||
def terminate(self):
|
||||
|
|
Loading…
Reference in New Issue