mirror of
https://github.com/bitcoin/bitcoin.git
synced 2025-11-11 22:50:59 +01:00
Implement BIP173 addresses and tests
This commit is contained in:
@@ -111,7 +111,26 @@ public:
|
||||
Process(script);
|
||||
}
|
||||
|
||||
void operator()(const CNoDestination &none) {}
|
||||
void operator()(const WitnessV0ScriptHash& scriptID)
|
||||
{
|
||||
CScriptID id;
|
||||
CRIPEMD160().Write(scriptID.begin(), 32).Finalize(id.begin());
|
||||
CScript script;
|
||||
if (keystore.GetCScript(id, script)) {
|
||||
Process(script);
|
||||
}
|
||||
}
|
||||
|
||||
void operator()(const WitnessV0KeyHash& keyid)
|
||||
{
|
||||
CKeyID id(keyid);
|
||||
if (keystore.HaveKey(id)) {
|
||||
vKeys.push_back(id);
|
||||
}
|
||||
}
|
||||
|
||||
template<typename X>
|
||||
void operator()(const X &none) {}
|
||||
};
|
||||
|
||||
const CWalletTx* CWallet::GetWalletTx(const uint256& hash) const
|
||||
|
||||
Reference in New Issue
Block a user