mirror of
https://github.com/ethereum/go-ethereum.git
synced 2026-07-26 06:36:43 +00:00
whisper: max number of peers fixed
This commit is contained in:
parent
ab64663b33
commit
0a7e128811
1 changed files with 6 additions and 1 deletions
|
|
@ -209,10 +209,15 @@ func initialize() {
|
||||||
nodeid = shh.NewIdentity()
|
nodeid = shh.NewIdentity()
|
||||||
}
|
}
|
||||||
|
|
||||||
|
maxPeers := 80
|
||||||
|
if *bootstrapMode {
|
||||||
|
maxPeers = 800
|
||||||
|
}
|
||||||
|
|
||||||
server = &p2p.Server{
|
server = &p2p.Server{
|
||||||
Config: p2p.Config{
|
Config: p2p.Config{
|
||||||
PrivateKey: nodeid,
|
PrivateKey: nodeid,
|
||||||
MaxPeers: 128,
|
MaxPeers: maxPeers,
|
||||||
Name: common.MakeName("whisper-go", "5.0"),
|
Name: common.MakeName("whisper-go", "5.0"),
|
||||||
Protocols: shh.Protocols(),
|
Protocols: shh.Protocols(),
|
||||||
ListenAddr: *argIP,
|
ListenAddr: *argIP,
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue