Add wallet method for finding spendable notes in a CTransaction

This commit is contained in:
Jack Grigg
2016-08-24 15:50:45 +12:00
parent 5db5e42ec3
commit 02e674555e
8 changed files with 264 additions and 2 deletions

View File

@@ -87,6 +87,8 @@ bool CBasicKeyStore::HaveWatchOnly() const
bool CBasicKeyStore::AddSpendingKey(const libzcash::SpendingKey &sk)
{
LOCK(cs_SpendingKeyStore);
mapSpendingKeys[sk.address()] = sk;
auto address = sk.address();
mapSpendingKeys[address] = sk;
mapNoteDecryptors[address] = ZCNoteDecryption(sk.viewing_key());
return true;
}