diff options
author | Eric Lombrozo <elombrozo@gmail.com> | 2013-01-18 07:01:05 -0800 |
---|---|---|
committer | Eric Lombrozo <elombrozo@gmail.com> | 2013-01-18 07:01:05 -0800 |
commit | 35c12d176e13d51456db8f0e9fa0c398891a1fab (patch) | |
tree | 732cc9b918ad35b652bc4a8c9781c86aa95affc3 /src | |
parent | 2c7847349d5d4b1f3e8480c5137c2e8f3e2a5f5c (diff) |
Moved SyncWithWallets out of ProcessMessage and into CTxMemPool::accept() so that when adding multiple wallets they will be aware of each other's transactions.
Diffstat (limited to 'src')
-rw-r--r-- | src/main.cpp | 3 |
1 files changed, 1 insertions, 2 deletions
diff --git a/src/main.cpp b/src/main.cpp index a6394e0bff..9ed4656b35 100644 --- a/src/main.cpp +++ b/src/main.cpp @@ -787,6 +787,7 @@ bool CTxMemPool::accept(CTransaction &tx, bool fCheckInputs, // If updated, erase old tx from wallet if (ptxOld) EraseFromWallets(ptxOld->GetHash()); + SyncWithWallets(hash, tx, NULL, true); printf("CTxMemPool::accept() : accepted %s (poolsz %"PRIszu")\n", hash.ToString().substr(0,10).c_str(), @@ -3411,7 +3412,6 @@ bool static ProcessMessage(CNode* pfrom, string strCommand, CDataStream& vRecv) bool fMissingInputs = false; if (tx.AcceptToMemoryPool(true, &fMissingInputs)) { - SyncWithWallets(inv.hash, tx, NULL, true); RelayTransaction(tx, inv.hash, vMsg); mapAlreadyAskedFor.erase(inv); vWorkQueue.push_back(inv.hash); @@ -3434,7 +3434,6 @@ bool static ProcessMessage(CNode* pfrom, string strCommand, CDataStream& vRecv) if (tx.AcceptToMemoryPool(true, &fMissingInputs2)) { printf(" accepted orphan tx %s\n", inv.hash.ToString().substr(0,10).c_str()); - SyncWithWallets(inv.hash, tx, NULL, true); RelayTransaction(tx, inv.hash, vMsg); mapAlreadyAskedFor.erase(inv); vWorkQueue.push_back(inv.hash); |