fix deadlocks
This commit is contained in:
parent
e542b24bc6
commit
257c0915b5
|
@ -360,7 +360,6 @@ class DeviceMgr(ThreadJob, PrintError):
|
|||
client.close()
|
||||
|
||||
def unpair_id(self, id_):
|
||||
with self.lock:
|
||||
xpub = self.xpub_by_id(id_)
|
||||
if xpub:
|
||||
self.unpair_xpub(xpub)
|
||||
|
@ -384,7 +383,7 @@ class DeviceMgr(ThreadJob, PrintError):
|
|||
return self.client_lookup(id_)
|
||||
|
||||
def client_for_keystore(self, plugin, handler, keystore, force_pair):
|
||||
with self.lock:
|
||||
self.print_error("getting client for keystore")
|
||||
plugin.update_status(handler, False)
|
||||
devices = self.scan_devices()
|
||||
xpub = keystore.xpub
|
||||
|
@ -395,6 +394,7 @@ class DeviceMgr(ThreadJob, PrintError):
|
|||
client = self.force_pair_xpub(plugin, handler, info, xpub, derivation, devices)
|
||||
if client:
|
||||
plugin.update_status(handler, True)
|
||||
self.print_error("end client for keystore")
|
||||
return client
|
||||
|
||||
def client_by_xpub(self, plugin, xpub, handler, devices):
|
||||
|
|
Loading…
Reference in New Issue