Browse Source

test

release/v0.1
jl777 9 years ago
parent
commit
ba6af59033
  1. 12
      iguana/iguana777.c
  2. 10
      iguana/iguana_realtime.c
  3. 2
      iguana/iguana_unspents.c

12
iguana/iguana777.c

@ -493,7 +493,7 @@ int32_t iguana_utxogen(struct supernet_info *myinfo,struct iguana_info *coin,int
}
if ( helperid < incr )
{
for (hdrsi=helperid; hdrsi<=max; hdrsi+=incr)
for (hdrsi=helperid; hdrsi<max; hdrsi+=incr)
num += iguana_helperB(coin,helperid,coin->bundles[hdrsi],convertflag);
}
while ( (n= iguana_convertfinished(coin)) < max )
@ -542,7 +542,15 @@ int32_t iguana_utxogen(struct supernet_info *myinfo,struct iguana_info *coin,int
coin->spendvectorsaved = (uint32_t)time(NULL);
coin->spendvalidated = 0;
printf("%s UTXOGEN spendvectorsaved <- %u\n",coin->symbol,coin->spendvectorsaved);
iguana_utxoaddr_gen(myinfo,coin,(coin->bundlescount - 1) * coin->chain->bundlesize);
if ( iguana_utxoaddr_gen(myinfo,coin,(coin->bundlescount - 1) * coin->chain->bundlesize) < 0 )
{
printf("retry utxoaddr_gen\n");
if ( iguana_utxoaddr_gen(myinfo,coin,(coin->bundlescount - 1) * coin->chain->bundlesize) < 0 )
{
printf("restart iguana: fatal error generating ledger file for %s\n",coin->symbol);
exit(1);
}
}
}
else
{

10
iguana/iguana_realtime.c

@ -635,7 +635,7 @@ void iguana_RTnewblock(struct iguana_info *coin,struct iguana_block *block)
iguana_RTpurge(coin,coin->firstRTheight);
}
n = (block->height - coin->RTheight) + 1;
for (i=0; i<n; i++)
for (i=0; i<n; i++,coin->RTheight++)
{
height = (coin->RTheight + i);
hdrsi = (height / coin->chain->bundlesize);
@ -644,9 +644,13 @@ void iguana_RTnewblock(struct iguana_info *coin,struct iguana_block *block)
{
iguana_RTblockadd(coin,addblock);
coin->lastRTheight = addblock->height;
} else printf("missing RTaddblock at i.%d RTheight.%d vs %p %d\n",i,coin->RTheight,addblock,addblock!=0?addblock->height:-1);
}
else
{
printf("missing RTaddblock at i.%d RTheight.%d vs %p %d\n",i,coin->RTheight,addblock,addblock!=0?addblock->height:-1);
break;
}
}
coin->RTheight += n;
printf(">= RTnewblock RTheight %d prev %d\n",coin->RTheight,coin->lastRTheight);
}
else if ( block->height == coin->lastRTheight )

2
iguana/iguana_unspents.c

@ -1122,7 +1122,7 @@ int32_t iguana_utxoaddr_check(struct supernet_info *myinfo,struct iguana_info *c
}
good++;
if ( ((good + bad) % 1000) == 0 )
printf("%s utxoaddr validate good.%d bad.%d | (if this is taking too long, just exit and restart iguana)\n",coin->symbol,good,bad);
printf("%s utxoaddr validate good.%d bad.%d%s\n",coin->symbol,good,bad,strcmp(coin->symbol,"BTC") == 0 ? " | (if this is taking too long, just exit and restart iguana)" : "");
return(0);
}

Loading…
Cancel
Save