make port always included in addr hash even if not specified
This commit is contained in:
parent
a603858c4b
commit
98ad4d2dd4
@ -277,6 +277,8 @@ Pool.prototype._deprioritizeAddr = function _deprioritizeAddr(addr) {
|
||||
* @param {Object}
|
||||
*/
|
||||
Pool.prototype._addAddr = function _addAddr(addr) {
|
||||
// Use default port if not specified
|
||||
addr.port = addr.port || this.network.port;
|
||||
|
||||
// make a unique key
|
||||
addr.hash = sha256(new Buffer(addr.ip.v6 + addr.ip.v4 + addr.port)).toString('hex');
|
||||
|
||||
Loading…
Reference in New Issue
Block a user