Test
This commit is contained in:
@@ -262,7 +262,7 @@ int32_t komodo_pax_opreturn(uint8_t *opret,int32_t maxsize)
|
|||||||
} else printf("fread.%d error != fsize.%d\n",retval,fsize);
|
} else printf("fread.%d error != fsize.%d\n",retval,fsize);
|
||||||
} else printf("fsize.%d > maxsize.%d or data[%d]\n",fsize,maxsize,(int32_t)sizeof(data));
|
} else printf("fsize.%d > maxsize.%d or data[%d]\n",fsize,maxsize,(int32_t)sizeof(data));
|
||||||
fclose(fp);
|
fclose(fp);
|
||||||
} else printf("couldnt open %s\n",fname);
|
} //else printf("couldnt open %s\n",fname);
|
||||||
return(n);
|
return(n);
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -683,11 +683,12 @@ void komodo_paxpricefeed(int32_t height,uint8_t *pricefeed,int32_t opretlen)
|
|||||||
numpvals = dpow_readprices(pricefeed,×tamp,&KMDBTC,&BTCUSD,&CNYUSD,pvals);
|
numpvals = dpow_readprices(pricefeed,×tamp,&KMDBTC,&BTCUSD,&CNYUSD,pvals);
|
||||||
memset(&zero,0,sizeof(zero));
|
memset(&zero,0,sizeof(zero));
|
||||||
komodo_stateupdate(height,0,0,0,zero,0,0,pvals,numpvals,0,0,0,0,0,0);
|
komodo_stateupdate(height,0,0,0,zero,0,0,pvals,numpvals,0,0,0,0,0,0);
|
||||||
|
if ( 1 )
|
||||||
{
|
{
|
||||||
int32_t i;
|
int32_t i;
|
||||||
for (i=0; i<numpvals; i++)
|
for (i=0; i<numpvals; i++)
|
||||||
printf("%u ",pvals[i]);
|
printf("%u ",pvals[i]);
|
||||||
printf("komodo_paxpricefeed vout OP_RETURN.%d prices numpvals.%d opretlen.%d\n",height,numpvals,opretlen);
|
printf("komodo_paxpricefeed vout OP_RETURN.%d prices numpvals.%d opretlen.%d kmdbtc %.8f BTCUSD %.8f CNYUSD %.8f\n",height,numpvals,opretlen,KMDBTC,BTCUSD,CNYUSD);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -411,7 +411,7 @@ CBlockTemplate* CreateNewBlock(const CScript& scriptPubKeyIn)
|
|||||||
ptr[i] = opret[i];
|
ptr[i] = opret[i];
|
||||||
txNew.vout[1].nValue = 0;
|
txNew.vout[1].nValue = 0;
|
||||||
//fprintf(stderr,"opretlen.%d\n",opretlen);
|
//fprintf(stderr,"opretlen.%d\n",opretlen);
|
||||||
} else printf("null opretlen for prices\n");
|
} //else printf("null opretlen for prices\n");
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
else if ( komodo_is_issuer() != 0 )
|
else if ( komodo_is_issuer() != 0 )
|
||||||
|
|||||||
Reference in New Issue
Block a user