From 580a4654365e410f090cc77d90b3d24c3559761f Mon Sep 17 00:00:00 2001 From: jl777 Date: Thu, 18 Jul 2019 02:57:59 -1100 Subject: [PATCH] Syntax --- src/komodo_nSPV_fullnode.h | 9 ++++----- 1 file changed, 4 insertions(+), 5 deletions(-) diff --git a/src/komodo_nSPV_fullnode.h b/src/komodo_nSPV_fullnode.h index 054077765..b5eba8ed3 100644 --- a/src/komodo_nSPV_fullnode.h +++ b/src/komodo_nSPV_fullnode.h @@ -243,15 +243,15 @@ int32_t NSPV_getaddresstxids(struct NSPV_txidsresp *ptr,char *coinaddr,bool isCC int32_t NSPV_mempoolfuncs(int32_t *vindexp,std::vector &txids,char *coinaddr,bool isCC,uint8_t funcid,uint256 txid,int32_t vout) { - int32_t num = 0,vini = 0,vouti = 0; uint8_t e=0,f=0; std::vector vopret; char destaddr[64]; + int32_t num = 0,vini = 0,vouti = 0; uint8_t evalcode=0,func=0; std::vector vopret; char destaddr[64]; *vindexp = -1; if ( mempool.size() == 0 ) return(0); if ( funcid == NSPV_MEMPOOL_CCEVALCODE ) { isCC = true; - e = vout & 0xff; - f = (vout >> 8) & 0xff; + evalcode = vout & 0xff; + func = (vout >> 8) & 0xff; } LOCK(mempool.cs); BOOST_FOREACH(const CTxMemPoolEntry &e,mempool.mapTx) @@ -280,8 +280,7 @@ int32_t NSPV_mempoolfuncs(int32_t *vindexp,std::vector &txids,char *coi CScript scriptPubKey = tx.vout[tx.vout.size()-1].scriptPubKey; if ( GetOpReturnData(scriptPubKey,vopret) != 0 ) { - uint8_t *ptr = vopret.data(); - if ( ptr[0] == e && ptr[1] == f ) + if ( vopret[0] == evalcode && vopret[1] == func ) { txids.push_back(hash); num++;