@@ -424,9 +424,9 @@ int32_t komodo_pending_withdraws(char *opretstr) // todo: enforce deterministic
|
||||
if ( n < sizeof(paxes)/sizeof(*paxes) )
|
||||
{
|
||||
paxes[n++] = pax;
|
||||
int32_t j; for (j=0; j<32; j++)
|
||||
printf("%02x",((uint8_t *)&pax->txid)[j]);
|
||||
printf(" %s.(kmdht.%d ht.%d marked.%u approved.%d validated %.8f) %.8f\n",pax->source,pax->height,pax->otherheight,pax->marked,pax->approved,dstr(pax->validated),dstr(pax->komodoshis));
|
||||
//int32_t j; for (j=0; j<32; j++)
|
||||
// printf("%02x",((uint8_t *)&pax->txid)[j]);
|
||||
//printf(" %s.(kmdht.%d ht.%d marked.%u approved.%d validated %.8f) %.8f\n",pax->source,pax->height,pax->otherheight,pax->marked,pax->approved,dstr(pax->validated),dstr(pax->komodoshis));
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -640,7 +640,7 @@ int32_t komodo_check_deposit(int32_t height,const CBlock& block) // verify above
|
||||
{
|
||||
printf("WOULD REJECT %s: ht.%d (%c) matched.%d vs num.%d\n",symbol,height,opcode,matched,num);
|
||||
// can easily happen depending on order of loading
|
||||
if ( height > 150000 )
|
||||
if ( height > 200000 )
|
||||
{
|
||||
printf("REJECT: ht.%d (%c) matched.%d vs num.%d\n",height,opcode,matched,num);
|
||||
return(-1);
|
||||
|
||||
@@ -429,6 +429,7 @@ uint64_t _komodo_paxprice(uint64_t *kmdbtcp,uint64_t *btcusdp,int32_t height,cha
|
||||
height -= 10;
|
||||
if ( (baseid= komodo_baseid(base)) >= 0 && (relid= komodo_baseid(rel)) >= 0 )
|
||||
{
|
||||
portable_mutex_lock(&komodo_mutex);
|
||||
for (i=NUM_PRICES-1; i>=0; i--)
|
||||
{
|
||||
ptr = &PVALS[36 * i];
|
||||
@@ -439,11 +440,13 @@ uint64_t _komodo_paxprice(uint64_t *kmdbtcp,uint64_t *btcusdp,int32_t height,cha
|
||||
*kmdbtcp = ptr[MAX_CURRENCIES + 1] / 539;
|
||||
*btcusdp = ptr[MAX_CURRENCIES + 2] / 539;
|
||||
}
|
||||
portable_mutex_unlock(&komodo_mutex);
|
||||
if ( kmdbtc != 0 && btcusd != 0 )
|
||||
return(komodo_paxcalc(&ptr[1],baseid,relid,basevolume,kmdbtc,btcusd));
|
||||
else return(0);
|
||||
}
|
||||
}
|
||||
portable_mutex_unlock(&komodo_mutex);
|
||||
} //else printf("paxprice invalid base.%s %d, rel.%s %d\n",base,baseid,rel,relid);
|
||||
return(0);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user