Browse Source

Merge Joinmarket-Org/joinmarket-clientserver#1528: No lock check on readonly

dafc1800ba no lock check on readonly (roshii)

Pull request description:

  Do not check wallet lock file for read-only
  Fixes https://github.com/JoinMarket-Org/joinmarket-clientserver/pull/1514#issuecomment-1668228340

ACKs for top commit:
  AdamISZ:
    tACK dafc1800ba , merging.

Tree-SHA512: 75497710deae573be65b6b8ab9b8ec9957d22f242716471023c33ab7821aaa58797bb5df43b7997d238834c2b3dc8afc27cfa68424bae6826bb23a96b1c2f158
master
Adam Gibson 2 years ago
parent
commit
c408041f8a
No known key found for this signature in database
GPG Key ID: 141001A1AF77F20B
  1. 5
      jmclient/jmclient/wallet_utils.py

5
jmclient/jmclient/wallet_utils.py

@ -1532,8 +1532,9 @@ def open_wallet(path, ask_for_password=True, password=None, read_only=False,
if ask_for_password and Storage.is_encrypted_storage_file(path):
while True:
try:
# Verify lock status before trying to open wallet.
Storage.verify_lock(path)
# Verify lock status if not read only before trying to open wallet.
if not read_only:
Storage.verify_lock(path)
# do not try empty password, assume unencrypted on empty password
pwd = get_password("Enter passphrase to decrypt wallet: ") or None
storage = Storage(path, password=pwd, read_only=read_only)

Loading…
Cancel
Save