From 739557ba92b4f8f71a460fec3b4447387fd7fae6 Mon Sep 17 00:00:00 2001 From: Yohan Graterol Date: Sun, 25 Feb 2018 18:37:42 -0500 Subject: [PATCH] Fix treasury calc --- consensus/ethash/consensus.go | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/consensus/ethash/consensus.go b/consensus/ethash/consensus.go index 144ff57d9e..93d5a75584 100644 --- a/consensus/ethash/consensus.go +++ b/consensus/ethash/consensus.go @@ -619,7 +619,7 @@ func accumulateRewards(config *params.ChainConfig, state *state.StateDB, header // Stake fee stakeReward := new(big.Int) stakeReward.Mul(reward, stakeFunds) - stakeReward.Div(treasuryReward, big.NewInt(100)) + stakeReward.Div(stakeReward, big.NewInt(100)) // Accumulate the rewards for the miner and any included uncles r := new(big.Int) @@ -636,7 +636,7 @@ func accumulateRewards(config *params.ChainConfig, state *state.StateDB, header if config.IsCallisto(header.Number) { reward.Sub(reward, treasuryReward) - reward.Sub(stakeReward, treasuryReward) + reward.Sub(reward, stakeReward) state.AddBalance(config.CallistoTreasuryAddress, treasuryReward) state.AddBalance(config.CallistoStakeAddress, stakeReward) }