Browse Source

Restore NSPV_utxosresp_purge

warmup
jl777 5 years ago
parent
commit
b444625676
  1. 14
      src/komodo_nSPV.h
  2. 11
      src/komodo_nSPV_defs.h

14
src/komodo_nSPV.h

@ -16,11 +16,11 @@
// todo:
// CC signing
// headers "sync" make sure it connects to prior blocks to notarization. use getinfo hdrht to get missing hdrs
// interest calculations are currently just using what is returned, it should calculate it from scratch
// 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
@ -118,6 +118,16 @@ int32_t NSPV_rwutxosresp(int32_t rwflag,uint8_t *serialized,struct NSPV_utxosres
return(len);
}
void NSPV_utxosresp_purge(struct NSPV_utxosresp *ptr)
{
if ( ptr != 0 )
{
if ( ptr->utxos != 0 )
free(ptr->utxos);
memset(ptr,0,sizeof(*ptr));
}
}
int32_t NSPV_rwntz(int32_t rwflag,uint8_t *serialized,struct NSPV_ntz *ptr)
{
int32_t len = 0;

11
src/komodo_nSPV_defs.h

@ -14,17 +14,6 @@
* *
******************************************************************************/
// todo:
// headers "sync" make sure it connects to prior blocks to notarization. use getinfo hdrht to get missing hdrs
// interest calculations are currently just using what is returned, it should calculate it from scratch
// 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_DEFSH
#define KOMODO_NSPV_DEFSH

Loading…
Cancel
Save