Browse Source

test

release/v0.1
jl777 9 years ago
parent
commit
69d67dac34
  1. 2
      iguana/iguana777.h
  2. 2
      iguana/iguana_bundles.c
  3. 4
      iguana/iguana_recv.c

2
iguana/iguana777.h

@ -29,7 +29,7 @@
#define IGUANA_HEIGHT 200
#define IGUANA_MAXPENDHDRS 1
#define _IGUANA_MAXPENDING 3 //64
#define _IGUANA_MAXPENDING 8 //64
#define _IGUANA_MAXBUNDLES 8
#define IGUANA_MAXACTIVEBUNDLES 32
#define IGUANA_MAXFILES 4096

2
iguana/iguana_bundles.c

@ -535,7 +535,7 @@ void iguana_bundlestats(struct iguana_info *coin,char *str)
}
/*for (i=0; i<n&&i<3; i++)
printf("(%.5f %.0f).%d ",coin->rankedbps[i][0],coin->rankedbps[i][1],coin->bundles[(int32_t)coin->rankedbps[i][1]]->numrecv);*/
if ( flag != 0 )
if ( 0 && flag != 0 )
printf("rem.%d issue.%d pend.%d | numranked.%d\n",n,origissue,pend,coin->peers.numranked);
}
}

4
iguana/iguana_recv.c

@ -697,9 +697,9 @@ int32_t iguana_pollQsPT(struct iguana_info *coin,struct iguana_peer *addr)
if ( bits256_nonz(hash2) > 0 )
{
bp = 0, bundlei = -2;
if ( (bp= iguana_bundlefind(coin,&bp,&bundlei,hash2)) == 0 || bp->numhashes < bp->n )
if ( (bp= iguana_bundlefind(coin,&bp,&bundlei,hash2)) == 0 || (bp->numhashes < bp->n && bp->bundleheight+coin->chain->bundlesize < coin->longestchain) )
{
printf("%s request hdr.(%s) numhashes.%d\n",addr!=0?addr->ipaddr:"local",hashstr,bp->numhashes);
//printf("%s request hdr.(%s) numhashes.%d\n",addr!=0?addr->ipaddr:"local",hashstr,bp->numhashes);
iguana_send(coin,addr,serialized,datalen);
addr->pendhdrs++;
flag++;

Loading…
Cancel
Save