Remove outdated misleading comment

This commit is contained in:
Gioacchino Mazzurco 2018-03-03 01:55:49 +01:00
parent 234daffec7
commit 9fbf56e592
No known key found for this signature in database
GPG Key ID: A1FBCA3872E87051

View File

@ -1119,12 +1119,7 @@ bool p3NetMgrIMPL::checkNetAddress()
#ifdef NETMGR_DEBUG
std::cerr << "p3NetMgrIMPL::checkNetAddress() Correcting Port to DEFAULT" << std::endl;
#endif
// Generate a default port from SSL id. The port will always be the
// same, but appear random from peer to peer.
// Random port avoids clashes, improves anonymity.
//
int new_port = htons(PQI_MIN_PORT_RNG + (RSRandom::random_u32() % (PQI_MAX_PORT - PQI_MIN_PORT_RNG)));
uint16_t new_port = htons(PQI_MIN_PORT_RNG + (RSRandom::random_u32() % (PQI_MAX_PORT - PQI_MIN_PORT_RNG)));
sockaddr_storage_setport(mLocalAddr, new_port);
addrChanged = true;