pool: handle host+port collision between inbound and outbound.
This commit is contained in:
parent
4fa6136ec4
commit
902fa59ca9
@ -510,6 +510,14 @@ Pool.prototype._handleLeech = function _handleLeech(socket) {
|
||||
return;
|
||||
}
|
||||
|
||||
// Some kind of weird port collision
|
||||
// between inbound ports and outbound ports.
|
||||
if (this.peers.get(addr)) {
|
||||
this.logger.debug('Port collision (%s).', hostname);
|
||||
socket.destroy();
|
||||
return;
|
||||
}
|
||||
|
||||
this.addLeech(socket);
|
||||
};
|
||||
|
||||
|
||||
Loading…
Reference in New Issue
Block a user