mirror of
https://bitbucket.org/theswgsource/src-1.2.git
synced 2026-07-14 00:01:30 -04:00
ConnectionServer: add altPublicBindAddress config option
This commit is contained in:
@@ -484,7 +484,9 @@ void ConnectionServer::handleConnectionServerIdMessage(const ConnectionServerId
|
||||
uint16 chatPort = 0;
|
||||
uint16 csPort = 0;
|
||||
if (c)
|
||||
{
|
||||
chatPort = c->getBindPort();
|
||||
}
|
||||
|
||||
if (cs)
|
||||
{
|
||||
@@ -493,12 +495,21 @@ void ConnectionServer::handleConnectionServerIdMessage(const ConnectionServerId
|
||||
|
||||
uint16 publicPort = 0;
|
||||
if (servicePublic)
|
||||
{
|
||||
publicPort = servicePublic->getBindPort();
|
||||
}
|
||||
|
||||
uint16 privatePort = 0;
|
||||
if (servicePrivate)
|
||||
{
|
||||
privatePort = servicePrivate->getBindPort();
|
||||
}
|
||||
|
||||
std::string clientServicePublicBindAddress = NetworkHandler::getHostName();
|
||||
std::string clientServicePublicBindAddress = ConfigConnectionServer::getPublicBindAddress();
|
||||
if (clientServicePublicBindAddress.empty())
|
||||
{
|
||||
clientServicePublicBindAddress = NetworkHandler::getHostName();
|
||||
}
|
||||
|
||||
NOT_NULL(gameService);
|
||||
NOT_NULL(chatService);
|
||||
@@ -508,7 +519,9 @@ void ConnectionServer::handleConnectionServerIdMessage(const ConnectionServerId
|
||||
sendToCentralProcess(ncs);
|
||||
}
|
||||
else
|
||||
{
|
||||
FATAL(true, ("Error in connection server startup"));
|
||||
}
|
||||
}
|
||||
|
||||
// ----------------------------------------------------------------------
|
||||
@@ -1566,4 +1579,4 @@ void ConnectionServer::setDone(char const *reasonfmt, ...)
|
||||
}
|
||||
}
|
||||
|
||||
// ======================================================================
|
||||
// ======================================================================
|
||||
|
||||
Reference in New Issue
Block a user