Browse Source

Test

etomic
jl777 8 years ago
parent
commit
a9c9d3364d
  1. 6
      iguana/exchanges/LP_remember.c
  2. 4
      iguana/exchanges/LP_utxos.c

6
iguana/exchanges/LP_remember.c

@ -427,13 +427,13 @@ cJSON *basilisk_remember(int64_t *KMDtotals,int64_t *BTCtotals,uint32_t requesti
if ( bits256_nonz(privkey) != 0 ) if ( bits256_nonz(privkey) != 0 )
{ {
privAm = privkey; privAm = privkey;
printf("set privAm <- %s\n",bits256_str(str,privAm)); //printf("set privAm <- %s\n",bits256_str(str,privAm));
} }
privkey = jbits256(item,"privBn"); privkey = jbits256(item,"privBn");
if ( bits256_nonz(privkey) != 0 ) if ( bits256_nonz(privkey) != 0 )
{ {
privBn = privkey; privBn = privkey;
printf("set privBn <- %s\n",bits256_str(str,privBn)); //printf("set privBn <- %s\n",bits256_str(str,privBn));
} }
expiration = juint(item,"expiration"); expiration = juint(item,"expiration");
state = jint(item,"state"); state = jint(item,"state");
@ -554,7 +554,7 @@ cJSON *basilisk_remember(int64_t *KMDtotals,int64_t *BTCtotals,uint32_t requesti
} else if ( finishedflag == 0 ) } else if ( finishedflag == 0 )
printf("%s not finished\n",fname); printf("%s not finished\n",fname);
} }
printf("alicepayment.%s bobpayment.%s bobdeposit.%s\n",alicepaymentaddr,bobpaymentaddr,bobdepositaddr); //printf("alicepayment.%s bobpayment.%s bobdeposit.%s\n",alicepaymentaddr,bobpaymentaddr,bobdepositaddr);
//printf("iambob.%d src.%s dest.%s bob.%s alice.%s pubA0.(%s)\n",iambob,src,dest,bobcoin,alicecoin,bits256_str(str,pubA0)); //printf("iambob.%d src.%s dest.%s bob.%s alice.%s pubA0.(%s)\n",iambob,src,dest,bobcoin,alicecoin,bits256_str(str,pubA0));
Adestaddr[0] = destaddr[0] = 0; Adestaddr[0] = destaddr[0] = 0;
Adest = Bdest = AAdest = ABdest = 0; Adest = Bdest = AAdest = ABdest = 0;

4
iguana/exchanges/LP_utxos.c

@ -412,13 +412,13 @@ struct LP_utxoinfo *LP_utxoadd(int32_t iambob,int32_t mypubsock,char *symbol,bit
bits256_str(str2,txid2); bits256_str(str2,txid2);
if ( strcmp(str,"7ea7481baf03698cbeb7b9cd0ed3f86f3c40debab72626516dda7e8d155630eb") == 0 || strcmp(str2,"7ea7481baf03698cbeb7b9cd0ed3f86f3c40debab72626516dda7e8d155630eb") == 0 ) if ( strcmp(str,"7ea7481baf03698cbeb7b9cd0ed3f86f3c40debab72626516dda7e8d155630eb") == 0 || strcmp(str2,"7ea7481baf03698cbeb7b9cd0ed3f86f3c40debab72626516dda7e8d155630eb") == 0 )
dispflag = 1; dispflag = 1;
if ( dispflag != 0 )
printf("%s iambob.%d %s utxoadd.(%.8f %.8f) %s %s\n",coinaddr,iambob,symbol,dstr(value),dstr(value2),bits256_str(str,txid),bits256_str(str2,txid2));
if ( LP_iseligible(&val,&val2,iambob,symbol,txid,vout,tmpsatoshis,txid2,vout2) <= 0 ) if ( LP_iseligible(&val,&val2,iambob,symbol,txid,vout,tmpsatoshis,txid2,vout2) <= 0 )
{ {
printf("utxoadd got spent txid value %.8f, value2 %.8f, tmpsatoshis %.8f\n",dstr(value),dstr(value2),dstr(tmpsatoshis)); printf("utxoadd got spent txid value %.8f, value2 %.8f, tmpsatoshis %.8f\n",dstr(value),dstr(value2),dstr(tmpsatoshis));
return(0); return(0);
} }
if ( dispflag != 0 )
printf("%.8f %.8f %s iambob.%d %s utxoadd.(%.8f %.8f) %s %s\n",dstr(val),dstr(val2),coinaddr,iambob,symbol,dstr(value),dstr(value2),bits256_str(str,txid),bits256_str(str2,txid2));
if ( (selector= LP_mempool_vinscan(&spendtxid,&spendvini,symbol,txid,vout,txid2,vout2)) >= 0 ) if ( (selector= LP_mempool_vinscan(&spendtxid,&spendvini,symbol,txid,vout,txid2,vout2)) >= 0 )
{ {
printf("utxoadd selector.%d in mempool %s vini.%d",selector,bits256_str(str,spendtxid),spendvini); printf("utxoadd selector.%d in mempool %s vini.%d",selector,bits256_str(str,spendtxid),spendvini);

Loading…
Cancel
Save