mirror of
https://github.com/bitcoin/bitcoin.git
synced 2026-01-20 15:19:07 +01:00
IsUsedDestination shouldn't use key id as script id for ScriptHash
Github-Pull: #17924
Rebased-From: 4b8f1e989f
This commit is contained in:
committed by
João Barbosa
parent
a5489c9892
commit
e2c45d89f7
@@ -1087,7 +1087,7 @@ bool CWallet::IsUsedDestination(const uint256& hash, unsigned int n) const
|
||||
if (GetDestData(wpkh_dest, "used", nullptr)) {
|
||||
return true;
|
||||
}
|
||||
ScriptHash sh_wpkh_dest(wpkh_dest);
|
||||
ScriptHash sh_wpkh_dest(GetScriptForDestination(wpkh_dest));
|
||||
if (GetDestData(sh_wpkh_dest, "used", nullptr)) {
|
||||
return true;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user