From 0dd516102540f37cf60652dff6c8db8a72278445 Mon Sep 17 00:00:00 2001 From: jl777 Date: Tue, 12 Jan 2016 20:32:37 -0300 Subject: [PATCH] test --- iguana/iguana_bundles.c | 33 +++++++++++++++------------------ 1 file changed, 15 insertions(+), 18 deletions(-) diff --git a/iguana/iguana_bundles.c b/iguana/iguana_bundles.c index c7997794d..d684692e2 100755 --- a/iguana/iguana_bundles.c +++ b/iguana/iguana_bundles.c @@ -506,32 +506,29 @@ void iguana_bundlestats(struct iguana_info *coin,char *str) //if ( origissue < 8 ) // origissue = 8; issue = origissue; - while ( issue > 0 && m++ < 100 ) + now = (uint32_t)time(NULL); + for (i=0; ibundles[(int32_t)coin->rankedbps[i][1]]) != 0 ) { - if ( (bp= coin->bundles[(int32_t)coin->rankedbps[i][1]]) != 0 ) + for (j=0; jn; j++) { - for (j=0; jn; j++) + if ( bits256_nonz(bp->hashes[j]) > 0 && (block= bp->blocks[j]) != 0 ) { - if ( bits256_nonz(bp->hashes[j]) > 0 && (block= bp->blocks[j]) != 0 ) + //printf("j.%d bp.%d %d %x lag.%d\n",j,bp->minrequests,block->numrequests,block->fpipbits,now - bp->issued[j]); + if ( block->numrequests <= bp->minrequests && block->fpipbits == 0 && (bp->issued[j] == 0 || now > bp->issued[j]+60) ) { - //printf("j.%d bp.%d %d %x lag.%d\n",j,bp->minrequests,block->numrequests,block->fpipbits,now - bp->issued[j]); - if ( block->numrequests <= bp->minrequests && block->fpipbits == 0 && (bp->issued[j] == 0 || now > bp->issued[j]+60) ) - { - printf("%d:%d.%d ",bp->hdrsi,j,block->numrequests); - flag++; - bp->issued[j] = now; - iguana_blockQ(coin,bp,j,bp->hashes[j],1); - if ( --issue < 0 ) - break; - } + printf("%d:%d.%d ",bp->hdrsi,j,block->numrequests); + flag++; + bp->issued[j] = now; + iguana_blockQ(coin,bp,j,bp->hashes[j],1); + if ( --issue < 0 ) + break; } } } - if ( issue <= 0 ) - break; } } /*for (i=0; i