From 411e2c22f82bfd8eb5a2ca6b3eeb4d54509b874c Mon Sep 17 00:00:00 2001 From: jl777 Date: Tue, 22 Mar 2016 14:15:26 -0300 Subject: [PATCH] test --- iguana/iguana_recv.c | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/iguana/iguana_recv.c b/iguana/iguana_recv.c index 0bfde50e7..93ff71680 100755 --- a/iguana/iguana_recv.c +++ b/iguana/iguana_recv.c @@ -195,7 +195,13 @@ void iguana_gotblockM(struct iguana_info *coin,struct iguana_peer *addr,struct i printf("validated.(%s)\n",bits256_str(str,origtxdata->block.RO.hash2)); copyflag = coin->enableCACHE; bp = 0, bundlei = -2; - if ( copyflag != 0 && recvlen != 0 && ((bp= iguana_bundlefind(coin,&bp,&bundlei,origtxdata->block.RO.hash2)) == 0 || (bp->blocks[bundlei] != 0 && bp->blocks[bundlei]->fpipbits == 0)) ) + bp = iguana_bundlefind(coin,&bp,&bundlei,origtxdata->block.RO.hash2); + if ( bp != 0 && bp->emitfinish != 0 ) + { + printf("got [%d:%d] with emitfinish.%u\n",bp->hdrsi,bundlei,bp->emitfinish); + return; + } + if ( copyflag != 0 && recvlen != 0 && (bp == 0 || (bp->blocks[bundlei] != 0 && bp->blocks[bundlei]->fpipbits == 0)) ) { req = iguana_bundlereq(coin,addr,'B',copyflag * recvlen); req->copyflag = 1;