Browse Source

test

release/v0.1
jl777 9 years ago
parent
commit
9926dc9145
  1. 2
      iguana/iguana_accept.c
  2. 7
      iguana/iguana_msg.c

2
iguana/iguana_accept.c

@ -195,7 +195,7 @@ int32_t iguana_process_msgrequestQ(struct supernet_info *myinfo,struct iguana_in
{
if ( (addr= msg->addr) != 0 && (len= iguana_peerblockrequest(coin,&coin->blockspace[sizeof(struct iguana_msghdr)],(int32_t)(sizeof(coin->blockspace) - sizeof(struct iguana_msghdr)),0,msg->hash2,0)) > 0 )
{
char str[65]; printf("msg Sendlen.%d block %s to %s\n",len,bits256_str(str,msg->hash2),addr->ipaddr);
//char str[65]; printf("msg Sendlen.%d block %s to %s\n",len,bits256_str(str,msg->hash2),addr->ipaddr);
iguana_queue_send(coin,addr,0,coin->blockspace,"block",len,0,0);
}
}

7
iguana/iguana_msg.c

@ -623,7 +623,12 @@ int32_t iguana_msgparser(struct iguana_info *coin,struct iguana_peer *addr,struc
len = n;
iguana_gotblockM(coin,addr,&txdata,rawmem->ptr,H,data,recvlen);
}
else printf("parse error block txn_count.%d, n.%d len.%d vs recvlen.%d from.(%s)\n",txdata.block.RO.txn_count,n,len,recvlen,addr->ipaddr);
else
{
for (i=0; i<recvlen; i++)
printf("%02x",data[i]);
printf(" parse error block txn_count.%d, n.%d len.%d vs recvlen.%d from.(%s)\n",txdata.block.RO.txn_count,n,len,recvlen,addr->ipaddr);
}
}
else
{

Loading…
Cancel
Save