X-Git-Url: https://git.novaco.in/?p=novacoin.git;a=blobdiff_plain;f=src%2Fmain.cpp;fp=src%2Fmain.cpp;h=805c0436d6817b5b77f085bbcf9ec896611319f2;hp=8cf70d14e07b304079ce92b9eb243b8fcc392b55;hb=e23488a379ace5a9a2a63ecf6b1c3ccfb6af833b;hpb=61a94025554ddd04d75635597444a4606fa9f81b diff --git a/src/main.cpp b/src/main.cpp index 8cf70d1..805c043 100644 --- a/src/main.cpp +++ b/src/main.cpp @@ -12,6 +12,7 @@ #include "interface.h" #include "checkqueue.h" #include "kernel.h" +#include "wallet.h" #include #include @@ -862,34 +863,6 @@ bool CMerkleTx::AcceptToMemoryPool() return AcceptToMemoryPool(txdb); } - - -bool CWalletTx::AcceptWalletTransaction(CTxDB& txdb, bool fCheckInputs) -{ - - { - LOCK(mempool.cs); - // Add previous supporting transactions first - for (CMerkleTx& tx : vtxPrev) - { - if (!(tx.IsCoinBase() || tx.IsCoinStake())) - { - uint256 hash = tx.GetHash(); - if (!mempool.exists(hash) && !txdb.ContainsTx(hash)) - tx.AcceptToMemoryPool(txdb, fCheckInputs); - } - } - return AcceptToMemoryPool(txdb, fCheckInputs); - } - return false; -} - -bool CWalletTx::AcceptWalletTransaction() -{ - CTxDB txdb("r"); - return AcceptWalletTransaction(txdb); -} - int CTxIndex::GetDepthInMainChain() const { // Read block header