Test
This commit is contained in:
@@ -711,7 +711,7 @@ uint32_t komodo_stake(arith_uint256 bnTarget,int32_t nHeight,uint256 txid,int32_
|
||||
fprintf(stderr,"%02x",((uint8_t *)&bnTarget)[i]);
|
||||
fprintf(stderr," iter.%d winner.%d coinage.%llu %d ht.%d gap.%d %.8f/%llu\n",iter,winner,(long long)coinage,(int32_t)(blocktime - txtime),nHeight,(int32_t)(blocktime - prevtime),dstr(value),(long long)supply);
|
||||
}
|
||||
if ( nHeight < 30 )
|
||||
if ( nHeight < 2 )
|
||||
return(blocktime);
|
||||
return(blocktime * winner);
|
||||
}
|
||||
@@ -796,7 +796,7 @@ int32_t komodo_check_deposit(int32_t height,const CBlock& block,uint32_t prevtim
|
||||
}
|
||||
bnTarget.SetCompact(block.nBits, &fNegative, &fOverflow);
|
||||
eligible = komodo_stake(bnTarget,height,block.vtx[txn_count-1].vin[0].prevout.hash,block.vtx[txn_count-1].vin[0].prevout.n,block.nTime,prevtime);
|
||||
if ( height >= 30 && (eligible == 0 || eligible > block.nTime) )
|
||||
if ( height >= 2 && (eligible == 0 || eligible > block.nTime) )
|
||||
{
|
||||
fprintf(stderr,"eligible.%u vs blocktime.%u, lag.%d\n",eligible,(uint32_t)block.nTime,(int32_t)(eligible - block.nTime));
|
||||
return(-1);
|
||||
|
||||
Reference in New Issue
Block a user