diff --git a/crypto777/OS_portable.h b/crypto777/OS_portable.h index ccdc774d3..9d4423615 100755 --- a/crypto777/OS_portable.h +++ b/crypto777/OS_portable.h @@ -358,7 +358,7 @@ void escape_code(char *escaped,char *str); void SaM_PrepareIndices(); // iguana_serdes.c -#define IGUANA_LOG2PACKETSIZE 21 +#define IGUANA_LOG2PACKETSIZE 22 #define IGUANA_MAXPACKETSIZE (1 << IGUANA_LOG2PACKETSIZE) struct iguana_msghdr { uint8_t netmagic[4]; char command[12]; uint8_t serdatalen[4],hash[4]; } PACKED; diff --git a/iguana/iguana_bundles.c b/iguana/iguana_bundles.c index b86570a78..ab0a6b779 100755 --- a/iguana/iguana_bundles.c +++ b/iguana/iguana_bundles.c @@ -615,7 +615,7 @@ struct iguana_block *iguana_bundleblock(struct iguana_info *coin,bits256 *hash2p int32_t iguana_bundleissuemissing(struct supernet_info *myinfo,struct iguana_info *coin,struct iguana_bundle *bp,int32_t priority,double mult) { - int32_t i,max,nonz,starti,lasti,firsti,lag,num,n=0; uint32_t now; bits256 hash2; double aveduration; struct iguana_peer *addr; struct iguana_block *block; + int32_t i,max,nonz,starti,lasti,firsti,lag,num,n=0; uint32_t now; bits256 hash2; double aveduration; struct iguana_peer *addr; //struct iguana_block *block; if ( coin->peers == 0 ) { printf("%s has no peers\n",coin->symbol); @@ -690,7 +690,7 @@ int32_t iguana_bundleissuemissing(struct supernet_info *myinfo,struct iguana_inf } if ( firsti >= 0 )//&& bp == coin->current ) { - printf("[%d] first missing.%d of %d\n",bp->hdrsi,firsti,nonz); + //printf("[%d] first missing.%d of %d\n",bp->hdrsi,firsti,nonz); iguana_bundleblock(coin,&hash2,bp,firsti); if ( bits256_nonz(hash2) != 0 ) { @@ -699,7 +699,7 @@ int32_t iguana_bundleissuemissing(struct supernet_info *myinfo,struct iguana_inf //if ( bp == coin->current ) // printf("iguana_bundleissuemissing.[%d:%d]\n",bp->hdrsi,i); n++; - printf("send reqPT [%d:%d]\n",bp->hdrsi,firsti); + //printf("send reqPT [%d:%d]\n",bp->hdrsi,firsti); iguana_sendblockreqPT(coin,0,bp,firsti,hash2,0); } } else printf("no hash for [%d:%d]\n",bp->hdrsi,firsti); diff --git a/iguana/iguana_recv.c b/iguana/iguana_recv.c index 2e1a5b742..8d998db67 100755 --- a/iguana/iguana_recv.c +++ b/iguana/iguana_recv.c @@ -747,7 +747,7 @@ void iguana_gotblockM(struct supernet_info *myinfo,struct iguana_info *coin,stru bp = 0, bundlei = -2; if ( iguana_bundlefind(coin,&bp,&bundlei,origtxdata->zblock.RO.prev_block) == 0 ) { - //printf("gotblockM: RTblock? %s\n",bits256_str(str,origtxdata->zblock.RO.hash2)); + printf("gotblockM: RTblock? %s\n",bits256_str(str,origtxdata->zblock.RO.hash2)); numtx = origtxdata->zblock.RO.txn_count; iguana_RTgotblock(coin,origtxdata->zblock.RO.hash2,data,&recvlen,&numtx); req = iguana_recv_bundlereq(coin,addr,0,H,data,recvlen,0,-1,origtxdata); @@ -774,6 +774,7 @@ void iguana_gotblockM(struct supernet_info *myinfo,struct iguana_info *coin,stru } if ( bp == 0 ) { + printf("gotblockM no bp %s\n",bits256_str(str,origtxdata->zblock.RO.hash2)); req = iguana_recv_bundlereq(coin,addr,0,H,data,recvlen,0,-1,origtxdata); queue_enqueue("recvQ",&coin->recvQ,&req->DL,0); return; @@ -787,6 +788,7 @@ void iguana_gotblockM(struct supernet_info *myinfo,struct iguana_info *coin,stru { req = iguana_recv_bundlereq(coin,addr,0,H,data,recvlen,0,-1,origtxdata); queue_enqueue("recvQ",&coin->recvQ,&req->DL,0); + printf("negative speculative return %s\n",bits256_str(str,origtxdata->zblock.RO.hash2)); return; } /*if ( block == 0 ) @@ -807,7 +809,7 @@ void iguana_gotblockM(struct supernet_info *myinfo,struct iguana_info *coin,stru } numtx = origtxdata->zblock.RO.txn_count; iguana_RTgotblock(coin,origtxdata->zblock.RO.hash2,data,&recvlen,&numtx); - //printf("getblockM update [%d:%d] %s\n",bp->hdrsi,bundlei,bits256_str(str,origtxdata->zblock.RO.hash2)); + printf("getblockM update [%d:%d] %s %p\n",bp->hdrsi,bundlei,bits256_str(str,origtxdata->zblock.RO.hash2),block); if ( block != 0 ) { if ( block->height < 0 )