From 517c76b0eb617262f24fffaf76b7494f342eb65a Mon Sep 17 00:00:00 2001 From: jl777 Date: Thu, 3 Nov 2016 16:13:57 -0300 Subject: [PATCH] test --- iguana/iguana_msg.c | 2 +- iguana/iguana_ramchain.c | 32 +------------------------------- 2 files changed, 2 insertions(+), 32 deletions(-) diff --git a/iguana/iguana_msg.c b/iguana/iguana_msg.c index 420de999d..0a4b703ac 100755 --- a/iguana/iguana_msg.c +++ b/iguana/iguana_msg.c @@ -976,7 +976,7 @@ int32_t iguana_msgparser(struct supernet_info *myinfo,struct iguana_info *coin,s if ( (n= iguana_gentxarray(myinfo,coin,rawmem,&txdata,&len,data,recvlen)) == recvlen || n == recvlen-1 ) { len = n; - iguana_gotblockM(myinfo,coin,addr,&txdata,rawmem->ptr,H,data,recvlen,fromcache,0*coin->chain->zcash); + iguana_gotblockM(myinfo,coin,addr,&txdata,rawmem->ptr,H,data,recvlen,fromcache,coin->chain->zcash); } else { diff --git a/iguana/iguana_ramchain.c b/iguana/iguana_ramchain.c index d95aa6022..8f710d419 100755 --- a/iguana/iguana_ramchain.c +++ b/iguana/iguana_ramchain.c @@ -1915,7 +1915,7 @@ long iguana_ramchain_data(struct supernet_info *myinfo,struct iguana_info *coin, block->RO.recvlen = 0; } } - else if ( 1 )//coin->chain->zcash == 0 ) + else { if ( (err= iguana_ramchain_verify(coin,ramchain)) == 0 ) { @@ -1952,36 +1952,6 @@ long iguana_ramchain_data(struct supernet_info *myinfo,struct iguana_info *coin, fpos = -1; } } - else - { - FILE *fp; - if ( (fp= fopen(fname,"wb")) != 0 ) - { - *B = RO; - rdata->scriptspace = ramchain->H.scriptoffset = scriptspace; - rdata->stackspace = ramchain->H.stacksize = stackspace; - /*if ( fwrite(rdata,1,sizeof(*rdata),fp) != sizeof(*rdata) ) - { - printf("ramchain_save error writing header.%s\n",fname); - fpos = -1; - } - fpos = (int32_t)ftell(fp); - fwrite(B,1,sizeof(*B),fp); - fwrite(T,rdata->numtxids,sizeof(*T),fp); - fwrite(U,rdata->numunspents,sizeof(*U),fp); - fwrite(S,rdata->numspends,sizeof(*S),fp);*/ - fclose(fp); - //printf("offset.%d vs allocsize.%d\n",(int32_t)offset,(int32_t)rdata->allocsize); - origtxdata->datalen = (int32_t)rdata->allocsize; - ramchain->H.ROflag = 0; - flag = 1; - bp->numtxids += rdata->numtxids; - bp->numunspents += rdata->numunspents; - bp->numspends += rdata->numspends; - if ( block != 0 && fpos >= 0 ) - block->fpos = fpos, block->fpipbits = (uint32_t)addr->ipbits; - } - } } if ( addr != 0 ) {