Browse Source

Test

etomic
jl777 8 years ago
parent
commit
8bb7d8e549
  1. 4
      iguana/exchanges/LP_nativeDEX.c

4
iguana/exchanges/LP_nativeDEX.c

@ -347,7 +347,7 @@ void LP_mainloop(char *myipaddr,struct LP_peerinfo *mypeer,uint16_t mypubport,in
void nn_tests(int32_t pullsock,char *pushaddr)
{
int32_t sock,n,timeout,m=0; //void *ptr;
if ( (sock= nn_socket(AF_SP,NN_PUSH)) >= 0 )
if ( (sock= nn_socket(AF_SP,NN_REQ)) >= 0 )
{
if ( nn_connect(sock,pushaddr) < 0 )
printf("connect error %s\n",nn_strerror(nn_errno()));
@ -404,7 +404,7 @@ void LPinit(uint16_t myport,uint16_t mypullport,uint16_t mypubport,double profit
} else printf("error getting myipaddr\n");
} else printf("error issuing curl\n");
nanomsg_transportname(0,pushaddr,myipaddr,mypullport);
if ( (pullsock= nn_socket(AF_SP,NN_PULL)) >= 0 )
if ( (pullsock= nn_socket(AF_SP,NN_REP)) >= 0 )
{
timeout = 1;
nn_setsockopt(pullsock,NN_SOL_SOCKET,NN_RCVTIMEO,&timeout,sizeof(timeout));

Loading…
Cancel
Save