Browse Source

Test

etomic
jl777 8 years ago
parent
commit
cbafd4830b
  1. 2
      basilisk/basilisk_tradebot.c
  2. 4
      basilisk/jumblr.c

2
basilisk/basilisk_tradebot.c

@ -346,7 +346,7 @@ double basilisk_request_listprocess(struct supernet_info *myinfo,struct basilisk
if ( (coin= iguana_coinfind(list[0].dest)) != 0 ) if ( (coin= iguana_coinfind(list[0].dest)) != 0 )
{ {
bitcoin_address(coinaddr,coin->chain->pubtype,myinfo->persistent_pubkey33,33); bitcoin_address(coinaddr,coin->chain->pubtype,myinfo->persistent_pubkey33,33);
balance = dstr(jumblr_balance(myinfo,coin,coinaddr)); balance = jumblr_balance(myinfo,coin,coinaddr);
printf("%s %s balance %.8f destamount %.8f aveprice %.8f maxamount %.8f minamount %.8f\n",list[0].dest,coinaddr,dstr(balance),dstr(destamount),aveprice,dstr(maxamount),dstr(minamount)); printf("%s %s balance %.8f destamount %.8f aveprice %.8f maxamount %.8f minamount %.8f\n",list[0].dest,coinaddr,dstr(balance),dstr(destamount),aveprice,dstr(maxamount),dstr(minamount));
} }
/*if ( (retstr= InstantDEX_available(myinfo,iguana_coinfind(list[0].dest),0,0,list[0].dest)) != 0 ) /*if ( (retstr= InstantDEX_available(myinfo,iguana_coinfind(list[0].dest),0,0,list[0].dest)) != 0 )

4
basilisk/jumblr.c

@ -215,11 +215,11 @@ int64_t jumblr_balance(struct supernet_info *myinfo,struct iguana_info *coin,cha
} }
else if ( (retstr= dex_getbalance(myinfo,coin,0,0,coin->symbol,addr)) != 0 ) else if ( (retstr= dex_getbalance(myinfo,coin,0,0,coin->symbol,addr)) != 0 )
{ {
printf("DEX retstr.(%s)\n",retstr); //printf("DEX retstr.(%s)\n",retstr);
if ( (retjson= cJSON_Parse(retstr)) != 0 ) if ( (retjson= cJSON_Parse(retstr)) != 0 )
{ {
balance = jdouble(retjson,"balance") * SATOSHIDEN; balance = jdouble(retjson,"balance") * SATOSHIDEN;
printf("GOT BALANCE %s %.8f\n",coin->symbol,balance); //printf("GOT BALANCE %s %.8f\n",coin->symbol,dstr(balance));
free_json(retjson); free_json(retjson);
} }
free(retstr); free(retstr);

Loading…
Cancel
Save