Browse Source

Test

etomic
jl777 7 years ago
parent
commit
43098788f7
  1. 4
      iguana/exchanges/LP_commands.c
  2. 3
      iguana/exchanges/LP_prices.c

4
iguana/exchanges/LP_commands.c

@ -172,9 +172,9 @@ trust(pubkey, trust)\n\
}
else if ( strcmp(method,"autoprice") == 0 )
{
if ( LP_autoprice(base,rel,price,jdouble(argjson,"margin")) >= 0 )
if ( LP_autoprice(base,rel,price,jdouble(argjson,"margin")) < 0 )
return(clonestr("{\"error\":\"couldnt set autoprice\"}"));
else return(clonestr("{\"error\":\"autoprice error\"}"));
else return(clonestr("{\"result\":\"success\"}"));
}
else if ( strcmp(method,"myprice") == 0 )
{

3
iguana/exchanges/LP_prices.c

@ -691,7 +691,7 @@ void prices_loop(void *ignore)
}
if ( (retjson= cJSON_Parse(retstr)) != 0 )
{
printf("got.(%s)\n",retstr);
//printf("got.(%s)\n",retstr);
if ( (array= jarray(&n,retjson,"result")) != 0 )
{
for (i=0; i<n; i++)
@ -702,6 +702,7 @@ void prices_loop(void *ignore)
if ( strncmp("BTC-",name,4) == 0 )
{
name += 4;
printf("%s\n",jprint(item,0));
if ( (coinpp= LP_priceinfofind(name)) != 0 )
{
coinpp->high = jdouble(item,"High");

Loading…
Cancel
Save