Add separate lock for SpendingKey key store operations

This commit is contained in:
Jack Grigg
2016-08-16 22:17:33 +12:00
parent b5c06c83b0
commit 0d7386916d
2 changed files with 5 additions and 4 deletions

View File

@@ -86,7 +86,7 @@ bool CBasicKeyStore::HaveWatchOnly() const
bool CBasicKeyStore::AddSpendingKey(const libzcash::SpendingKey &sk)
{
LOCK(cs_KeyStore);
LOCK(cs_SpendingKeyStore);
mapSpendingKeys[sk.address()] = sk;
return true;
}