jl777 7 years ago
parent
commit
f10cbf5eea
  1. 3
      iguana/exchanges/LP_rpc.c

3
iguana/exchanges/LP_rpc.c

@ -598,6 +598,8 @@ int32_t LP_importaddress(char *symbol,char *address)
double _LP_getestimatedrate(struct iguana_info *coin)
{
char buf[512],*retstr; cJSON *errjson; double rate = 0.00000020;
if ( coin->rate == 0. || time(NULL) > time(NULL) > coin->ratetime+6 )
{
sprintf(buf,"[%d]",strcmp(coin->symbol,"BTC") == 0 ? 6 : 2);
if ( (retstr= LP_apicall(coin,coin->electrum==0?"estimatefee" : "blockchain.estimatefee",buf)) != 0 )
{
@ -621,6 +623,7 @@ double _LP_getestimatedrate(struct iguana_info *coin)
}
free(retstr);
}
}
return(rate);
}

Loading…
Cancel
Save