Browse Source

test

release/v0.1
jl777 9 years ago
parent
commit
02face6522
  1. 6
      iguana/iguana_bundles.c
  2. 2
      iguana/main.c

6
iguana/iguana_bundles.c

@ -392,9 +392,10 @@ int32_t iguana_bundleissue(struct iguana_info *coin,struct iguana_bundle *bp,int
if ( block->peerid == 0 ) if ( block->peerid == 0 )
{ {
//printf("<%d>.%d ",i,j); //printf("<%d>.%d ",i,j);
if ( 1 || block->fpipbits != 0 ) if ( block->fpipbits != 0 )
{ {
hashes[k++] = bp->hashes[i]; hashes[k++] = bp->hashes[i];
bp->issued[i] = now;
block->issued = now; block->issued = now;
block->peerid = j + 1; block->peerid = j + 1;
block->numrequests++; block->numrequests++;
@ -422,7 +423,6 @@ int32_t iguana_bundleissue(struct iguana_info *coin,struct iguana_bundle *bp,int
} }
} }
} }
bp->issued[i] = now;
} }
if ( k > 0 ) if ( k > 0 )
{ {
@ -440,7 +440,7 @@ int32_t iguana_bundleissue(struct iguana_info *coin,struct iguana_bundle *bp,int
} }
} }
//printf("minval.%d maxval.%d\n",minval,maxval); //printf("minval.%d maxval.%d\n",minval,maxval);
//if ( 0 && minval != maxval ) if ( minval != maxval )
{ {
r = rand() % numpeers; r = rand() % numpeers;
oldest = 0; oldest = 0;

2
iguana/main.c

@ -332,7 +332,7 @@ void mainloop(struct supernet_info *myinfo)
for (i=0; i<IGUANA_MAXCOINS; i++) for (i=0; i<IGUANA_MAXCOINS; i++)
if ( (coin= Coins[i]) != 0 && coin->active != 0 && (bp= coin->current) != 0 ) if ( (coin= Coins[i]) != 0 && coin->active != 0 && (bp= coin->current) != 0 )
{ {
iguana_bundleissue(coin,bp,bp->hdrsi,100); iguana_bundleissue(coin,bp,bp->n,100);
if ( (ptr= queue_dequeue(&balancesQ,0)) != 0 ) if ( (ptr= queue_dequeue(&balancesQ,0)) != 0 )
{ {
if ( ptr->bp != 0 && ptr->coin != 0 ) if ( ptr->bp != 0 && ptr->coin != 0 )

Loading…
Cancel
Save