Browse Source

test

etomic
jl777 8 years ago
parent
commit
ce0bc281ee
  1. 8
      iguana/dpow/dpow_network.c

8
iguana/dpow/dpow_network.c

@ -1227,7 +1227,7 @@ int32_t dpow_nanomsg_update(struct supernet_info *myinfo)
} }
if ( dp != 0 && crc32 == np->crc32 ) if ( dp != 0 && crc32 == np->crc32 )
{ {
//char str[65]; printf("%s RECV ht.%d ch.%08x (%d) crc32.%08x:%08x datalen.%d:%d firstz.%d\n",bits256_str(str,np->srchash),np->height,np->channel,size,np->crc32,crc32,np->datalen,(int32_t)(size - sizeof(*np)),firstz); char str[65]; printf("%s RECV ht.%d ch.%08x (%d) crc32.%08x:%08x datalen.%d:%d firstz.%d\n",bits256_str(str,np->srchash),np->height,np->channel,size,np->crc32,crc32,np->datalen,(int32_t)(size - sizeof(*np)),firstz);
if ( i == myinfo->numdpows ) if ( i == myinfo->numdpows )
printf("received nnpacket for (%s)\n",np->symbol); printf("received nnpacket for (%s)\n",np->symbol);
else else
@ -1248,9 +1248,9 @@ int32_t dpow_nanomsg_update(struct supernet_info *myinfo)
} }
//dp->crcs[firstz] = crc32; //dp->crcs[firstz] = crc32;
} }
} //else printf("crc error from.%d %x vs %x or no dp.%p [%s]\n",np->senderind,crc32,np->crc32,dp,np->symbol); } else printf("crc error from.%d %x vs %x or no dp.%p [%s]\n",np->senderind,crc32,np->crc32,dp,np->symbol);
} //else printf("ignore.%d np->datalen.%d %d (size %d - %ld) [%s]\n",np->senderind,np->datalen,(int32_t)(size-sizeof(*np)),size,sizeof(*np),np->symbol); } else printf("ignore.%d np->datalen.%d %d (size %d - %ld) [%s]\n",np->senderind,np->datalen,(int32_t)(size-sizeof(*np)),size,sizeof(*np),np->symbol);
} //else printf("wrong version from.%d %02x %02x size.%d [%s]\n",np->senderind,np->version0,np->version1,size,np->symbol); } else printf("wrong version from.%d %02x %02x size.%d [%s]\n",np->senderind,np->version0,np->version1,size,np->symbol);
} else printf("illegal size.%d\n",size); } else printf("illegal size.%d\n",size);
if ( np != 0 ) if ( np != 0 )
nn_freemsg(np), np = 0; nn_freemsg(np), np = 0;

Loading…
Cancel
Save