mirror of
https://github.com/LBRYFoundation/lbcwallet.git
synced 2025-08-23 17:47:29 +00:00
wallet: unblock Lock() when the wallet is shutdown
This commit is contained in:
parent
79bcb8365c
commit
1f05a9858b
1 changed files with 4 additions and 1 deletions
|
@ -1379,7 +1379,10 @@ func (w *Wallet) Unlock(passphrase []byte, lock <-chan time.Time) error {
|
||||||
|
|
||||||
// Lock locks the wallet's address manager.
|
// Lock locks the wallet's address manager.
|
||||||
func (w *Wallet) Lock() {
|
func (w *Wallet) Lock() {
|
||||||
w.lockRequests <- struct{}{}
|
select {
|
||||||
|
case <-w.quitChan():
|
||||||
|
case w.lockRequests <- struct{}{}:
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
// Locked returns whether the account manager for a wallet is locked.
|
// Locked returns whether the account manager for a wallet is locked.
|
||||||
|
|
Loading…
Add table
Reference in a new issue