From b4cf30250748bab3b400c7dc50d21cf9b9a8dff3 Mon Sep 17 00:00:00 2001 From: jl777 Date: Fri, 12 Apr 2019 02:16:22 -1100 Subject: [PATCH] Move to right function --- src/komodo_gateway.h | 16 ++++++++-------- 1 file changed, 8 insertions(+), 8 deletions(-) diff --git a/src/komodo_gateway.h b/src/komodo_gateway.h index 225dfd5a7..274cf426c 100644 --- a/src/komodo_gateway.h +++ b/src/komodo_gateway.h @@ -2164,11 +2164,19 @@ int32_t komodo_cbopretsize(uint64_t flags) return(size); } +extern uint256 Queued_reconsiderblock; + void komodo_cbopretupdate(int32_t forceflag) { static uint32_t lasttime,lastcrypto,lastbtc,pending; static uint32_t pricebits[4],cryptoprices[KOMODO_MAXPRICES],forexprices[sizeof(Forex)/sizeof(*Forex)]; int32_t size; uint32_t flags=0,now; CBlockIndex *pindex; + fprintf(stderr,"Queued_reconsiderblock %s\n",Queued_reconsiderblock.GetHex().c_str()); + if ( Queued_reconsiderblock != zeroid ) + { + komodo_reconsiderblock(Queued_reconsiderblock); + Queued_reconsiderblock = zeroid; + } if ( forceflag != 0 && pending != 0 ) { while ( pending != 0 ) @@ -2625,18 +2633,10 @@ void komodo_pricesinit() } } -extern uint256 Queued_reconsiderblock; - void komodo_pricesupdate(int32_t height,CBlock *pblock) { static int numprices; static uint32_t *ptr32; static int64_t *ptr64,*tmpbuf; int32_t ind,offset,width; int64_t correlated,smoothed; uint64_t seed,rngval; uint32_t rawprices[KOMODO_MAXPRICES],buf[PRICES_MAXDATAPOINTS*2]; - fprintf(stderr,"Queued_reconsiderblock %s\n",Queued_reconsiderblock.GetHex().c_str()); - if ( Queued_reconsiderblock != zeroid ) - { - komodo_reconsiderblock(Queued_reconsiderblock); - Queued_reconsiderblock = zeroid; - } width = PRICES_DAYWINDOW;//(2*PRICES_DAYWINDOW + PRICES_SMOOTHWIDTH); if ( numprices == 0 ) {