Browse Source

test

release/v0.1
jl777 9 years ago
parent
commit
498e3a58fe
  1. 7
      iguana/iguana_accept.c
  2. 2
      iguana/iguana_instantdex.c
  3. 2
      iguana/iguana_msg.c

7
iguana/iguana_accept.c

@ -226,11 +226,8 @@ int32_t iguana_process_msgrequestQ(struct supernet_info *myinfo,struct iguana_in
}
else if ( msg->type == MSG_QUOTE )
{
if ( (ap= instantdex_quotefind(myinfo,coin,msg->addr,msg->hash2)) == 0 )
{
if ( (len= instantdex_quoterequest(myinfo,coin,&coin->blockspace[sizeof(struct iguana_msghdr)],sizeof(coin->blockspace),msg->addr,msg->hash2)) > 0 )
iguana_queue_send(coin,msg->addr,0,coin->blockspace,"quote",len,0,0);
}
if ( (len= instantdex_quoterequest(myinfo,coin,&coin->blockspace[sizeof(struct iguana_msghdr)],sizeof(coin->blockspace),msg->addr,msg->hash2)) > 0 )
iguana_queue_send(coin,msg->addr,0,coin->blockspace,"quote",len,0,0);
}
}
free(msg);

2
iguana/iguana_instantdex.c

@ -833,7 +833,7 @@ struct iguana_bundlereq *instantdex_recvquotes(struct iguana_info *coin,struct i
int32_t i,len,m = 0; uint8_t serialized[10000];
if ( req->addr == 0 )
return(0);
printf("received quotes.%d from (%s)\n",n,req->addr->ipaddr);
printf("received quotehashes.%d from (%s)\n",n,req->addr->ipaddr);
for (i=1; i<n; i++)
{
if ( instantdex_quotefind(0,coin,req->addr,quotes[i]) != 0 )

2
iguana/iguana_msg.c

@ -601,7 +601,7 @@ int32_t iguana_msgparser(struct iguana_info *coin,struct iguana_peer *addr,struc
}
else if ( strcmp(H->command,"quote") == 0 )
{
printf("got quote from %s\n",addr->ipaddr);
printf("got full quote from %s\n",addr->ipaddr);
instantdex_quote(myinfo,coin,addr,data,recvlen);
return(0);
}

Loading…
Cancel
Save