Remove mindiff cap for 100% PoS
This commit is contained in:
@@ -466,7 +466,7 @@ bool CCoinsViewCache::HaveInputs(const CTransaction& tx) const
|
||||
const COutPoint &prevout = tx.vin[i].prevout;
|
||||
const CCoins* coins = AccessCoins(prevout.hash);
|
||||
if (!coins || !coins->IsAvailable(prevout.n)) {
|
||||
fprintf(stderr,"HaveInputs missing input %s/v%d\n",prevout.hash.ToString().c_str(),prevout.n);
|
||||
//fprintf(stderr,"HaveInputs missing input %s/v%d\n",prevout.hash.ToString().c_str(),prevout.n);
|
||||
return false;
|
||||
}
|
||||
}
|
||||
|
||||
@@ -1094,13 +1094,16 @@ uint32_t komodo_stake(int32_t validateflag,arith_uint256 bnTarget,int32_t nHeigh
|
||||
blocktime = prevtime+57;
|
||||
if ( value == 0 || txtime == 0 || blocktime == 0 || prevtime == 0 )
|
||||
{
|
||||
fprintf(stderr,"komodo_stake null %.8f %u %u %u\n",dstr(value),txtime,blocktime,prevtime);
|
||||
//fprintf(stderr,"komodo_stake null %.8f %u %u %u\n",dstr(value),txtime,blocktime,prevtime);
|
||||
return(0);
|
||||
}
|
||||
bnMaxPoSdiff.SetCompact(KOMODO_MINDIFF_NBITS,&fNegative,&fOverflow);
|
||||
bnMaxPoSdiff = (bnMaxPoSdiff / arith_uint256(4));
|
||||
if ( bnTarget < bnMaxPoSdiff )
|
||||
bnTarget = bnMaxPoSdiff;
|
||||
if ( ASSETCHAINS_STAKED != 100 || nHeight < 2000 )
|
||||
{
|
||||
bnMaxPoSdiff.SetCompact(KOMODO_MINDIFF_NBITS,&fNegative,&fOverflow);
|
||||
bnMaxPoSdiff = (bnMaxPoSdiff / arith_uint256(4));
|
||||
if ( bnTarget < bnMaxPoSdiff )
|
||||
bnTarget = bnMaxPoSdiff;
|
||||
}
|
||||
if ( (minage= nHeight*3) > 6000 ) // about 100 blocks
|
||||
minage = 6000;
|
||||
pindex = 0;
|
||||
|
||||
Reference in New Issue
Block a user