mirror of
https://github.com/kvazar-network/kevacoin.git
synced 2025-01-12 08:08:25 +00:00
Merge pull request #3701
09ec3af
AddToWallet implies BindWallet (Wladimir J. van der Laan)
This commit is contained in:
commit
913e90db9a
@ -471,6 +471,7 @@ bool CWallet::AddToWallet(const CWalletTx& wtxIn, bool fFromLoadWallet)
|
||||
if (fFromLoadWallet)
|
||||
{
|
||||
mapWallet[hash] = wtxIn;
|
||||
mapWallet[hash].BindWallet(this);
|
||||
AddToSpends(hash);
|
||||
}
|
||||
else
|
||||
|
@ -352,9 +352,7 @@ ReadKeyValue(CWallet* pwallet, CDataStream& ssKey, CDataStream& ssValue,
|
||||
CWalletTx wtx;
|
||||
ssValue >> wtx;
|
||||
CValidationState state;
|
||||
if (CheckTransaction(wtx, state) && (wtx.GetHash() == hash) && state.IsValid())
|
||||
wtx.BindWallet(pwallet);
|
||||
else
|
||||
if (!(CheckTransaction(wtx, state) && (wtx.GetHash() == hash) && state.IsValid()))
|
||||
return false;
|
||||
|
||||
// Undo serialize changes in 31600
|
||||
|
Loading…
Reference in New Issue
Block a user