Browse Source

test

release/v0.1
jl777 9 years ago
parent
commit
1f2aab0a1a
  1. 3
      iguana/iguana_tx.c

3
iguana/iguana_tx.c

@ -73,6 +73,8 @@ int32_t iguana_vinset(struct iguana_info *coin,uint8_t *scriptspace,int32_t heig
if ( height >= 0 && height < coin->chain->bundlesize*coin->bundlescount && (bp= coin->bundles[height / coin->chain->bundlesize]) != 0 ) if ( height >= 0 && height < coin->chain->bundlesize*coin->bundlescount && (bp= coin->bundles[height / coin->chain->bundlesize]) != 0 )
{ {
ramchain = (bp == coin->current) ? &coin->RTramchain : &bp->ramchain; ramchain = (bp == coin->current) ? &coin->RTramchain : &bp->ramchain;
if ( (rdata= ramchain->H.data) != 0 && i < rdata->numspends )
{
S = RAMCHAIN_PTR(rdata,Soffset); S = RAMCHAIN_PTR(rdata,Soffset);
X = RAMCHAIN_PTR(rdata,Xoffset); X = RAMCHAIN_PTR(rdata,Xoffset);
T = RAMCHAIN_PTR(rdata,Toffset); T = RAMCHAIN_PTR(rdata,Toffset);
@ -92,6 +94,7 @@ int32_t iguana_vinset(struct iguana_info *coin,uint8_t *scriptspace,int32_t heig
vin->scriptlen = s->scriptlen; vin->scriptlen = s->scriptlen;
vin->vinscript = scriptspace; vin->vinscript = scriptspace;
iguana_ramchain_spendtxid(coin,&unspentind,&vin->prev_hash,T,rdata->numtxids,X,rdata->numexternaltxids,s); iguana_ramchain_spendtxid(coin,&unspentind,&vin->prev_hash,T,rdata->numtxids,X,rdata->numexternaltxids,s);
} else printf("null rdata.%p error height.%d i.%d\n",rdata,height,i);
} else printf("error getting rdata.%p height.%d\n",rdata,height); } else printf("error getting rdata.%p height.%d\n",rdata,height);
if ( err != 0 ) if ( err != 0 )
return(-err); return(-err);

Loading…
Cancel
Save