Less timestamp penalty for inbound connections
- was over 2 days, but PyBM will only spread those with more recent than 3 hours. So it's now set to 2 hours
This commit is contained in:
parent
d7076626c2
commit
a6dbb1e37e
|
@ -796,7 +796,7 @@ class receiveDataThread(threading.Thread):
|
||||||
for stream in self.remoteStreams:
|
for stream in self.remoteStreams:
|
||||||
knownnodes.knownNodes[stream][state.Peer(self.peer.host, self.remoteNodeIncomingPort)] = int(time.time())
|
knownnodes.knownNodes[stream][state.Peer(self.peer.host, self.remoteNodeIncomingPort)] = int(time.time())
|
||||||
if not self.initiatedConnection:
|
if not self.initiatedConnection:
|
||||||
knownnodes.knownNodes[stream][state.Peer(self.peer.host, self.remoteNodeIncomingPort)] -= 162000 # penalise inbound, 2 days minus 3 hours
|
knownnodes.knownNodes[stream][state.Peer(self.peer.host, self.remoteNodeIncomingPort)] -= 7200 # penalise inbound, 2 hours
|
||||||
shared.needToWriteKnownNodesToDisk = True
|
shared.needToWriteKnownNodesToDisk = True
|
||||||
|
|
||||||
self.sendverack()
|
self.sendverack()
|
||||||
|
|
Loading…
Reference in New Issue
Block a user