From bfc916c6e364de10ef88769fe10800e52d2498e2 Mon Sep 17 00:00:00 2001 From: Christopher Franko Date: Thu, 24 Sep 2015 15:34:44 -0400 Subject: [PATCH] qf2 --- core/chain_util.go | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/core/chain_util.go b/core/chain_util.go index 6ce13af541..680355e5b7 100644 --- a/core/chain_util.go +++ b/core/chain_util.go @@ -40,11 +40,12 @@ var ( // given the parent block's time and difficulty. func CalcDifficulty(time, parentTime uint64, parentNumber, parentDiff *big.Int) *big.Int { diff := new(big.Int) + adjust := new(big.Int) if parentNumber.Cmp(params.HardFork1) < 0 { - adjust := new(big.Int).Div(parentDiff, params.DifficultyBoundDivisor) + adjust = new(big.Int).Div(parentDiff, params.DifficultyBoundDivisor) } else { - adjust := new(big.Int).Div(parentDiff, params.DifficultyBoundDivisor2) + adjust = new(big.Int).Div(parentDiff, params.DifficultyBoundDivisor2) } bigTime := new(big.Int)