From 74f6d90153a4d62eefaa8a49f98dc6ed8e0100f6 Mon Sep 17 00:00:00 2001 From: Jeffrey Wilcke Date: Thu, 6 Aug 2015 13:29:06 +0200 Subject: cmd/utils, core: disable exp diff for olympic net --- core/chain_util.go | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'core') diff --git a/core/chain_util.go b/core/chain_util.go index 34f6c8d0a..84b462ce3 100644 --- a/core/chain_util.go +++ b/core/chain_util.go @@ -32,7 +32,7 @@ import ( var ( blockHashPre = []byte("block-hash-") blockNumPre = []byte("block-num-") - expDiffPeriod = big.NewInt(100000) + ExpDiffPeriod = big.NewInt(100000) ) // CalcDifficulty is the difficulty adjustment algorithm. It returns @@ -57,7 +57,7 @@ func CalcDifficulty(time, parentTime uint64, parentNumber, parentDiff *big.Int) } periodCount := new(big.Int).Add(parentNumber, common.Big1) - periodCount.Div(periodCount, expDiffPeriod) + periodCount.Div(periodCount, ExpDiffPeriod) if periodCount.Cmp(common.Big1) > 0 { // diff = diff + 2^(periodCount - 2) expDiff := periodCount.Sub(periodCount, common.Big2) -- cgit v1.2.3