Skip to content

Commit

Permalink
Merge pull request dashpay#5759 from UdjinM6/bp26532
Browse files Browse the repository at this point in the history
backport: partial merge bitcoin#26532: wallet: bugfix, invalid crypted key "checksum_valid" set
  • Loading branch information
PastaPastaPasta authored and ogabrielides committed Dec 22, 2023
1 parent b1e9e05 commit 8364e4b
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/wallet/walletdb.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -388,7 +388,7 @@ ReadKeyValue(CWallet* pwallet, CDataStream& ssKey, CDataStream& ssValue,
if (!ssValue.eof()) {
uint256 checksum;
ssValue >> checksum;
if ((checksum_valid = Hash(vchPrivKey) != checksum)) {
if (!(checksum_valid = Hash(vchPrivKey) == checksum)) {
strErr = "Error reading wallet database: Crypted key corrupt";
return false;
}
Expand Down

0 comments on commit 8364e4b

Please sign in to comment.