This commit is contained in:
jl777
2019-07-09 02:00:15 -11:00
parent ecc5aebc44
commit 9a3cf79c37
3 changed files with 11 additions and 8 deletions

View File

@@ -23,6 +23,7 @@
// CC signing
// make sure to sanity check all vector lengths on receipt
// make sure no files are updated (this is to allow nSPV=1 and later nSPV=0 without affecting database)
// bug: under load, fullnode was returning all 0 nServices
#ifndef KOMODO_NSPV_H
#define KOMODO_NSPV_H

View File

@@ -210,15 +210,17 @@ int32_t NSPV_sendrawtransaction(struct NSPV_broadcastresp *ptr,uint8_t *data,int
{
LOCK(cs_main);
ptr->txid = tx.GetHash();
fprintf(stderr,"addmempool transaction %s\n",ptr->txid.GetHex().c_str());
fprintf(stderr,"try to addmempool transaction %s\n",ptr->txid.GetHex().c_str());
if ( myAddtomempool(tx) != 0 )
{
int32_t i;
for (i=0; i<n; i++)
fprintf(stderr,"%02x",data[i]);
fprintf(stderr," relay transaction %s retcode.%d\n",ptr->txid.GetHex().c_str(),ptr->retcode);
ptr->retcode = 1;
else ptr->retcode = 0;
int32_t i;
for (i=0; i<n; i++)
fprintf(stderr,"%02x",data[i]);
fprintf(stderr," relay transaction %s retcode.%d\n",ptr->txid.GetHex().c_str(),ptr->retcode);
RelayTransaction(tx);
RelayTransaction(tx);
} else ptr->retcode = -3;
} else ptr->retcode = -1;
return(sizeof(*ptr));
}

View File

@@ -1843,7 +1843,7 @@ bool StopNode()
for (int i=0; i<MAX_OUTBOUND_CONNECTIONS; i++)
semOutbound->post();
if (fAddressesInitialized)
if (KOMODO_NSPV == 0 && fAddressesInitialized)
{
DumpAddresses();
fAddressesInitialized = false;