mirror of
https://gitlab.com/pulsechaincom/erigon-pulse.git
synced 2024-12-24 12:37:16 +00:00
Removed goroutine from "Run"
This commit is contained in:
parent
db89c3e1a3
commit
455241debb
@ -2,6 +2,7 @@ package eth
|
||||
|
||||
import (
|
||||
"bytes"
|
||||
"fmt"
|
||||
"math"
|
||||
"math/big"
|
||||
|
||||
@ -98,15 +99,14 @@ func runEthProtocol(txPool txPool, chainManager chainManager, blockPool blockPoo
|
||||
}
|
||||
err = self.handleStatus()
|
||||
if err == nil {
|
||||
go func() {
|
||||
for {
|
||||
err = self.handle()
|
||||
if err != nil {
|
||||
self.blockPool.RemovePeer(self.id)
|
||||
break
|
||||
}
|
||||
for {
|
||||
err = self.handle()
|
||||
if err != nil {
|
||||
fmt.Println(err)
|
||||
self.blockPool.RemovePeer(self.id)
|
||||
break
|
||||
}
|
||||
}()
|
||||
}
|
||||
}
|
||||
return
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user