jl777 7 years ago
parent
commit
3ef1dc4807
  1. 1
      iguana/exchanges/LP_nativeDEX.c
  2. 1
      iguana/exchanges/LP_ordermatch.c
  3. 6
      iguana/exchanges/LP_portfolio.c
  4. 1
      iguana/exchanges/LP_prices.c
  5. 4
      iguana/exchanges/LP_rpc.c

1
iguana/exchanges/LP_nativeDEX.c

@ -322,7 +322,6 @@ int32_t LP_utxos_sync(struct LP_peerinfo *peer)
if ( coin->inactive != 0 || coin->obooktime == 0 )
continue;
total = 0;
printf("from utxos_sync\n");
LP_listunspent_both(coin->symbol,coin->smartaddr);
if ( (array= LP_address_utxos(coin,coin->smartaddr,1)) != 0 )
{

1
iguana/exchanges/LP_ordermatch.c

@ -695,7 +695,6 @@ int32_t LP_listunspent_both(char *symbol,char *coinaddr)
//printf("issue path electrum.%p\n",coin->electrum);
//if ( coin->electrum != 0 && (array= electrum_address_gethistory(symbol,coin->electrum,&array,coinaddr)) != 0 )
// free_json(array);
printf("listunspent_both\n");
n = LP_listunspent_issue(symbol,coinaddr);
}
else

6
iguana/exchanges/LP_portfolio.c

@ -89,7 +89,7 @@ char *LP_portfolio()
{
HASH_ITER(hh,LP_coins,coin,tmp)
{
if ( coin->inactive != 0 )
if ( coin->inactive != 0 || coin->obooktime == 0 )
continue;
if ( iter == 0 )
{
@ -184,12 +184,16 @@ char *LP_portfolio_goal(char *symbol,double goal)
coin->goal = kmdbtc * 0.5;
if ( (coin= LP_coinfind("BTC")) != 0 && coin->inactive == 0 )
coin->goal = kmdbtc * 0.5;
if ( coin->goal != 0 )
coin->obooktime = (uint32_t)time(NULL);
return(LP_portfolio());
}
else if ( (coin= LP_coinfind(symbol)) != 0 && coin->inactive == 0 )
{
coin->goal = goal;
printf("set %s goal %f\n",coin->symbol,goal);
if ( coin->goal != 0 )
coin->obooktime = (uint32_t)time(NULL);
return(LP_portfolio());
} else return(clonestr("{\"error\":\"cant set goal for inactive coin\"}"));
}

1
iguana/exchanges/LP_prices.c

@ -224,7 +224,6 @@ char *LP_pubkey_trustset(bits256 pubkey,uint32_t trustval)
uint64_t LP_unspents_metric(struct iguana_info *coin,char *coinaddr)
{
cJSON *array,*item; int32_t i,n; uint64_t metric=0,total;
printf("unspents metric\n");
LP_listunspent_both(coin->symbol,coinaddr);
if ( (array= LP_address_utxos(coin,coinaddr,1)) != 0 )
{

4
iguana/exchanges/LP_rpc.c

@ -491,9 +491,7 @@ int32_t LP_listunspent_issue(char *symbol,char *coinaddr)
{
n = cJSON_GetArraySize(retjson);
printf("LP_listunspent_issue.%s %s.%d %s\n",symbol,coinaddr,n,jprint(retjson,0));
if ( strcmp(symbol,"ARG") == 0 )
assert(0);
}
}
}
else
{

Loading…
Cancel
Save