diff options
author | obscuren <geffobscura@gmail.com> | 2015-03-23 23:47:05 +0800 |
---|---|---|
committer | obscuren <geffobscura@gmail.com> | 2015-03-23 23:47:05 +0800 |
commit | 211cb03f83c8bdfd29af31fd27dc531dfcb13630 (patch) | |
tree | 7c1296a6194db41a8d8b25a89dd7aa442d6b4fe5 /core/chain_manager.go | |
parent | 253ecdc8bba1b522e80fdee69410854f19a5a972 (diff) | |
parent | 9562a9840f783e6252ebc6fb8da62b81004f62e8 (diff) | |
download | dexon-211cb03f83c8bdfd29af31fd27dc531dfcb13630.tar dexon-211cb03f83c8bdfd29af31fd27dc531dfcb13630.tar.gz dexon-211cb03f83c8bdfd29af31fd27dc531dfcb13630.tar.bz2 dexon-211cb03f83c8bdfd29af31fd27dc531dfcb13630.tar.lz dexon-211cb03f83c8bdfd29af31fd27dc531dfcb13630.tar.xz dexon-211cb03f83c8bdfd29af31fd27dc531dfcb13630.tar.zst dexon-211cb03f83c8bdfd29af31fd27dc531dfcb13630.zip |
Merge branch 'develop' of github.com-obscure:ethereum/go-ethereum into develop
Diffstat (limited to 'core/chain_manager.go')
-rw-r--r-- | core/chain_manager.go | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/core/chain_manager.go b/core/chain_manager.go index 192fa1df0..56ea4de9f 100644 --- a/core/chain_manager.go +++ b/core/chain_manager.go @@ -32,8 +32,10 @@ type StateQuery interface { func CalcDifficulty(block, parent *types.Header) *big.Int { diff := new(big.Int) - min := big.NewInt(2048) - adjust := new(big.Int).Div(parent.Difficulty, min) + diffBoundDiv := big.NewInt(2048) + min := big.NewInt(131072) + + adjust := new(big.Int).Div(parent.Difficulty, diffBoundDiv) if (block.Time - parent.Time) < 8 { diff.Add(parent.Difficulty, adjust) } else { |