Browse Source

Test

etomic
jl777 8 years ago
parent
commit
ed0f1f14b2
  1. 6
      iguana/exchanges/LP_nativeDEX.c
  2. 2
      iguana/exchanges/LP_prices.c

6
iguana/exchanges/LP_nativeDEX.c

@ -108,7 +108,9 @@ int32_t LP_pullsock_check(char *myipaddr,int32_t pubsock,int32_t pullsock,double
if ( (retstr= stats_JSON(argjson,"127.0.0.1",0)) != 0 )
{
printf("%s PULL.[%d] %s -> (%s)\n",myipaddr != 0 ? myipaddr : "127.0.0.1",recvsize,jsonstr,retstr);
free(retstr);
if ( pubsock >= 0 )
LP_send(pubsock,retstr,1);
else free(retstr);
}
}
portable_mutex_unlock(&LP_commandmutex);
@ -133,7 +135,7 @@ int32_t LP_subsock_check(struct LP_peerinfo *peer)
portable_mutex_lock(&LP_commandmutex);
if ( (retstr= stats_JSON(argjson,"127.0.0.1",0)) != 0 )
{
//printf("%s RECV.[%d] %s\n",peer->ipaddr,recvsize,(char *)ptr);
printf("%s SUB.[%d] %s\n",peer->ipaddr,recvsize,(char *)ptr);
free(retstr);
}
portable_mutex_unlock(&LP_commandmutex);

2
iguana/exchanges/LP_prices.c

@ -375,6 +375,8 @@ char *LP_pricestr(char *base,char *rel)
{
retjson = cJSON_CreateObject();
jaddstr(retjson,"result","success");
jaddstr(retjson,"method","postprice");
jaddbits256(retjson,"pubkey",LP_mypubkey);
jaddstr(retjson,"base",base);
jaddstr(retjson,"rel",rel);
jaddnum(retjson,"price",price);

Loading…
Cancel
Save