diff options
author | Gavin Andresen <gavinandresen@gmail.com> | 2013-01-23 09:29:01 -0800 |
---|---|---|
committer | Gavin Andresen <gavinandresen@gmail.com> | 2013-01-23 09:29:01 -0800 |
commit | 09c69c03f701b1f4ab2bd734eca375f939e4d728 (patch) | |
tree | 76666ee78f3dbb3b6168d1b4ed5c563f06eb6391 /src/main.cpp | |
parent | c429f2b062140843f42b78d70278279c6be74441 (diff) | |
parent | 35c12d176e13d51456db8f0e9fa0c398891a1fab (diff) |
Merge pull request #2187 from CodeShark/SyncWithWalletsFix
Bugfix - Moved SyncWithWallets out of ProcessMessage and into CTxMemPool::accept()
Diffstat (limited to 'src/main.cpp')
-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 67f05817fe..f6fce00e6e 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(), @@ -3420,7 +3421,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); @@ -3443,7 +3443,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); |