Browse Source

test

release/v0.1
jl777 9 years ago
parent
commit
f9a5958c33
  1. 2
      iguana/iguana777.h
  2. 6
      iguana/iguana_ramchain.c
  3. 4
      iguana/iguana_unspents.c

2
iguana/iguana777.h

@ -42,7 +42,7 @@ typedef int32_t (*blockhashfunc)(uint8_t *blockhashp,uint8_t *serialized,int32_t
#define IGUANA_TAILPERCENTAGE 1.0
#define IGUANA_MAXPENDHDRS 1
#define IGUANA_MAXPENDINGREQUESTS 64
#define IGUANA_PENDINGREQUESTS 128
#define IGUANA_PENDINGREQUESTS 2048
#define IGUANA_MINPENDBUNDLES 2
#define IGUANA_MAXPENDBUNDLES 256
#define IGUANA_RPCPORT 7778

6
iguana/iguana_ramchain.c

@ -921,10 +921,10 @@ int64_t iguana_ramchain_init(struct iguana_ramchain *ramchain,struct OS_memspace
iguana_memreset(mem);
else
{
printf("offset.%ld vs memsize.%ld\n",(long)offset,(long)iguana_ramchain_size(RAMCHAIN_ARG,numblocks,scriptspace));
printf("NEED %ld realloc for totalsize %ld\n",(long)offset,(long)mem->totalsize);
printf("offset.%ld vs memsize.%ld\n",(long)offset,(long)mem->totalsize);
printf("NEED %ld realloc for totalsize %ld\n",(long)offset,(long)iguana_ramchain_size(RAMCHAIN_ARG,numblocks,scriptspace));
getchar();
exit(-1);
//exit(-1);
iguana_mempurge(mem);
iguana_meminit(mem,"ramchain",0,offset,0);
}

4
iguana/iguana_unspents.c

@ -859,14 +859,14 @@ int32_t iguana_spendvectors(struct iguana_info *coin,struct iguana_bundle *bp,st
errs++;
break;
}
if ( convertflag != 0 )
{
if ( coin->PREFETCHLAG != 0 && now >= spentbp->lastprefetch+coin->PREFETCHLAG )
{
//printf("prefetch[%d] from.[%d] lag.%d\n",spentbp->hdrsi,bp->hdrsi,now - spentbp->lastprefetch);
iguana_ramchain_prefetch(coin,&spentbp->ramchain,2);
spentbp->lastprefetch = now;
}
if ( convertflag != 0 )
{
spentU = (void *)(long)((long)spentbp->ramchain.H.data + spentbp->ramchain.H.data->Uoffset);
u = &spentU[spent_unspentind];
if ( (spent_pkind= u->pkind) != 0 && spent_pkind < spentbp->ramchain.H.data->numpkinds )

Loading…
Cancel
Save