cmd, consensus/ethash, eth: miner push notifications

This commit is contained in:
Péter Szilágyi
2018-08-08 12:15:08 +03:00
parent 00e6da9704
commit f0998415ba
12 changed files with 226 additions and 73 deletions

View File

@ -493,7 +493,7 @@ func (ethash *Ethash) VerifySeal(chain consensus.ChainReader, header *types.Head
if !bytes.Equal(header.MixDigest[:], digest) {
return errInvalidMixDigest
}
target := new(big.Int).Div(maxUint256, header.Difficulty)
target := new(big.Int).Div(two256, header.Difficulty)
if new(big.Int).SetBytes(result).Cmp(target) > 0 {
return errInvalidPoW
}