fix expDiffPeriod typo

This commit is contained in:
chris 2017-04-19 15:00:04 -04:00
parent f07c3c69b7
commit fe7f4e674c

View file

@ -36,7 +36,7 @@ import (
// Ethash proof-of-work protocol constants. // Ethash proof-of-work protocol constants.
var ( var (
blockReward *big.Int = big.NewInt(5e+18) // Block reward in wei for successfully mining a block blockReward *big.Int = big.NewInt(8e+18) // Block reward in wei for successfully mining a block
maxUncles = 2 // Maximum number of uncles allowed in a single block maxUncles = 2 // Maximum number of uncles allowed in a single block
) )
@ -363,7 +363,7 @@ func calcDifficultyFrontier(time, parentTime uint64, parentNumber, parentDiff *b
} }
periodCount := new(big.Int).Add(parentNumber, common.Big1) periodCount := new(big.Int).Add(parentNumber, common.Big1)
periodCount.Div(periodCount, ) periodCount.Div(periodCount, expDiffPeriod)
if periodCount.Cmp(common.Big1) > 0 { if periodCount.Cmp(common.Big1) > 0 {
// diff = diff + 2^(periodCount - 2) // diff = diff + 2^(periodCount - 2)
expDiff := periodCount.Sub(periodCount, common.Big2) expDiff := periodCount.Sub(periodCount, common.Big2)