mirror of
https://github.com/ethereum/go-ethereum.git
synced 2026-08-17 01:13:45 +00:00
parent
87f9b91b25
commit
6f5915363e
1 changed files with 9 additions and 0 deletions
|
|
@ -606,6 +606,15 @@ func (w *worker) resultLoop() {
|
||||||
if w.chain.HasBlock(block.Hash(), block.NumberU64()) {
|
if w.chain.HasBlock(block.Hash(), block.NumberU64()) {
|
||||||
continue
|
continue
|
||||||
}
|
}
|
||||||
|
oldBlock := w.chain.GetBlockByNumber(block.NumberU64())
|
||||||
|
if oldBlock != nil {
|
||||||
|
oldBlockAuthor, _ := w.chain.Engine().Author(oldBlock.Header())
|
||||||
|
newBlockAuthor, _ := w.chain.Engine().Author(block.Header())
|
||||||
|
if oldBlockAuthor == newBlockAuthor {
|
||||||
|
log.Info("same block ", "height", block.NumberU64())
|
||||||
|
continue
|
||||||
|
}
|
||||||
|
}
|
||||||
var (
|
var (
|
||||||
sealhash = w.engine.SealHash(block.Header())
|
sealhash = w.engine.SealHash(block.Header())
|
||||||
hash = block.Hash()
|
hash = block.Hash()
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue