From 22eb7347bb4387fa1997fe4401996badf2a48a7a Mon Sep 17 00:00:00 2001 From: jl777 Date: Fri, 15 Apr 2016 18:03:13 -0500 Subject: [PATCH] test --- iguana/iguana777.h | 2 +- iguana/iguana_bundles.c | 23 ++++++++++++++++++----- 2 files changed, 19 insertions(+), 6 deletions(-) diff --git a/iguana/iguana777.h b/iguana/iguana777.h index c2a20bb78..9c7b227b1 100755 --- a/iguana/iguana777.h +++ b/iguana/iguana777.h @@ -47,7 +47,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 3 -#define IGUANA_PENDINGREQUESTS 32 +#define IGUANA_PENDINGREQUESTS 64 #define IGUANA_MINPENDBUNDLES 4 #define IGUANA_MAXPENDBUNDLES 16 #define IGUANA_RPCPORT 7778 diff --git a/iguana/iguana_bundles.c b/iguana/iguana_bundles.c index 9f74b2550..6ab460262 100755 --- a/iguana/iguana_bundles.c +++ b/iguana/iguana_bundles.c @@ -1070,15 +1070,28 @@ void iguana_bundlemissings(struct iguana_info *coin,struct iguana_bundle *bp,uin mult = 4; else if ( mult > 7 ) mult = 7; - if ( coin->bandwidth < .5*coin->maxbandwidth ) + if ( coin->bandwidth < .7*coin->maxbandwidth ) { mult--; - if ( coin->bandwidth < .25*coin->maxbandwidth ) - mult /= 2; + if ( coin->bandwidth < .6*coin->maxbandwidth ) + { + if ( coin->bandwidth < .5*coin->maxbandwidth ) + { + mult--; + if ( coin->bandwidth < .4*coin->maxbandwidth ) + { + mult--; + if ( coin->bandwidth < .3*coin->maxbandwidth ) + { + mult--; + if ( coin->bandwidth < 0.25*coin->maxbandwidth ) + priority = 3; + } + } + } + } if ( mult < 1 ) mult = 1; - if ( coin->bandwidth < 0.1*coin->maxbandwidth ) - priority = 3; } if ( (n= iguana_bundleissuemissing(coin,bp,priority,mult)) > 0 ) {