CC fixes for nSPV and others (#30)

- Remove adding txfee inputs for gateways claim
- FULLNODE and SUPERLITE macros
- Filter SetCCtxids with txid from oprert
- Fix for nServices of fullnode
- Use SetCCtxids_nSPV for some more CCs
- Fix addnormalinputs and add checking if utxo spent in mempool
This commit is contained in:
Mihailo Milenkovic
2019-08-12 14:16:46 +03:00
committed by GitHub
parent 450ac5c5ea
commit a7204d9f85
24 changed files with 184 additions and 95 deletions

View File

@@ -374,7 +374,7 @@ void TxToJSON(const CTransaction& tx, const uint256 hashBlock, UniValue& entry)
const CTxOut& txout = tx.vout[i];
UniValue out(UniValue::VOBJ);
out.push_back(Pair("value", ValueFromAmount(txout.nValue)));
if ( KOMODO_NSPV <= 0 && ASSETCHAINS_SYMBOL[0] == 0 && tx.nLockTime >= 500000000 && (tipindex= chainActive.LastTip()) != 0 )
if ( KOMODO_NSPV_FULLNODE && ASSETCHAINS_SYMBOL[0] == 0 && tx.nLockTime >= 500000000 && (tipindex= chainActive.LastTip()) != 0 )
{
int64_t interest; int32_t txheight; uint32_t locktime;
interest = komodo_accrued_interest(&txheight,&locktime,tx.GetHash(),i,0,txout.nValue,(int32_t)tipindex->GetHeight());
@@ -1366,7 +1366,7 @@ UniValue sendrawtransaction(const UniValue& params, bool fHelp)
bool fOverrideFees = false;
if (params.size() > 1)
fOverrideFees = params[1].get_bool();
if ( KOMODO_NSPV <= 0 )
if ( KOMODO_NSPV_FULLNODE )
{
CCoinsViewCache &view = *pcoinsTip;
const CCoins* existingCoins = view.AccessCoins(hashTx);