diff options
-rw-r--r-- | src/server/bnetserver/CMakeLists.txt | 2 | ||||
-rw-r--r-- | src/server/bnetserver/Main.cpp | 15 | ||||
-rw-r--r-- | src/server/bnetserver/Realms/RealmList.cpp | 14 |
3 files changed, 15 insertions, 16 deletions
diff --git a/src/server/bnetserver/CMakeLists.txt b/src/server/bnetserver/CMakeLists.txt index 3fa4abf034a..9d99ac7f0c5 100644 --- a/src/server/bnetserver/CMakeLists.txt +++ b/src/server/bnetserver/CMakeLists.txt @@ -8,7 +8,7 @@ # WITHOUT ANY WARRANTY, to the extent permitted by law; without even the # implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. -########### authserver ############### +########### bnetserver ############### file(GLOB_RECURSE sources_authentication Authentication/*.cpp Authentication/*.h) file(GLOB_RECURSE sources_realms Realms/*.cpp Realms/*.h) diff --git a/src/server/bnetserver/Main.cpp b/src/server/bnetserver/Main.cpp index 5e0d728d724..ff891304bd3 100644 --- a/src/server/bnetserver/Main.cpp +++ b/src/server/bnetserver/Main.cpp @@ -81,7 +81,7 @@ int main(int argc, char** argv) TC_LOG_INFO("server.bnetserver", "Using SSL version: %s (library: %s)", OPENSSL_VERSION_TEXT, SSLeay_version(SSLEAY_VERSION)); TC_LOG_INFO("server.bnetserver", "Using Boost version: %i.%i.%i", BOOST_VERSION / 100000, BOOST_VERSION / 100 % 1000, BOOST_VERSION % 100); - // authserver PID file creation + // bnetserver PID file creation std::string pidFile = sConfigMgr->GetStringDefault("PidFile", ""); if (!pidFile.empty()) { @@ -151,32 +151,31 @@ bool StartDB() std::string dbstring = sConfigMgr->GetStringDefault("LoginDatabaseInfo", ""); if (dbstring.empty()) { - TC_LOG_ERROR("server.authserver", "Database not specified"); + TC_LOG_ERROR("server.bnetserver", "Database not specified"); return false; } int32 worker_threads = sConfigMgr->GetIntDefault("LoginDatabase.WorkerThreads", 1); if (worker_threads < 1 || worker_threads > 32) { - TC_LOG_ERROR("server.authserver", "Improper value specified for LoginDatabase.WorkerThreads, defaulting to 1."); + TC_LOG_ERROR("server.bnetserver", "Improper value specified for LoginDatabase.WorkerThreads, defaulting to 1."); worker_threads = 1; } int32 synch_threads = sConfigMgr->GetIntDefault("LoginDatabase.SynchThreads", 1); if (synch_threads < 1 || synch_threads > 32) { - TC_LOG_ERROR("server.authserver", "Improper value specified for LoginDatabase.SynchThreads, defaulting to 1."); + TC_LOG_ERROR("server.bnetserver", "Improper value specified for LoginDatabase.SynchThreads, defaulting to 1."); synch_threads = 1; } - // NOTE: While authserver is singlethreaded you should keep synch_threads == 1. Increasing it is just silly since only 1 will be used ever. if (!LoginDatabase.Open(dbstring, uint8(worker_threads), uint8(synch_threads))) { - TC_LOG_ERROR("server.authserver", "Cannot connect to database"); + TC_LOG_ERROR("server.bnetserver", "Cannot connect to database"); return false; } - TC_LOG_INFO("server.authserver", "Started auth database connection pool."); + TC_LOG_INFO("server.bnetserver", "Started auth database connection pool."); sLog->SetRealmId(0); // Enables DB appenders when realm is set. return true; } @@ -198,7 +197,7 @@ void KeepDatabaseAliveHandler(const boost::system::error_code& error) { if (!error) { - TC_LOG_INFO("server.authserver", "Ping MySQL to keep connection alive"); + TC_LOG_INFO("server.bnetserver", "Ping MySQL to keep connection alive"); LoginDatabase.KeepAlive(); _dbPingTimer.expires_from_now(boost::posix_time::minutes(_dbPingInterval)); diff --git a/src/server/bnetserver/Realms/RealmList.cpp b/src/server/bnetserver/Realms/RealmList.cpp index 6e2c1e99e56..8d6edb12b5c 100644 --- a/src/server/bnetserver/Realms/RealmList.cpp +++ b/src/server/bnetserver/Realms/RealmList.cpp @@ -35,7 +35,7 @@ ip::tcp::endpoint Realm::GetAddressForClient(ip::address const& clientAddr) cons realmIp = clientAddr; else { - // Assume that user connecting from the machine that authserver is located on + // Assume that user connecting from the machine that bnetserver is located on // has all realms available in his local network realmIp = LocalAddress; } @@ -117,7 +117,7 @@ void RealmList::UpdateRealms(boost::system::error_code const& error) if (error) return; - TC_LOG_INFO("server.authserver", "Updating Realm List..."); + TC_LOG_INFO("server.bnetserver", "Updating Realm List..."); PreparedStatement* stmt = LoginDatabase.GetPreparedStatement(LOGIN_SEL_REALMLIST); PreparedQueryResult result = LoginDatabase.Query(stmt); @@ -139,7 +139,7 @@ void RealmList::UpdateRealms(boost::system::error_code const& error) boost::asio::ip::tcp::resolver::iterator endPoint = _resolver->resolve(externalAddressQuery, ec); if (endPoint == end || ec) { - TC_LOG_ERROR("server.authserver", "Could not resolve address %s", fields[2].GetString().c_str()); + TC_LOG_ERROR("server.bnetserver", "Could not resolve address %s", fields[2].GetString().c_str()); continue; } @@ -149,7 +149,7 @@ void RealmList::UpdateRealms(boost::system::error_code const& error) endPoint = _resolver->resolve(localAddressQuery, ec); if (endPoint == end || ec) { - TC_LOG_ERROR("server.authserver", "Could not resolve address %s", fields[3].GetString().c_str()); + TC_LOG_ERROR("server.bnetserver", "Could not resolve address %s", fields[3].GetString().c_str()); continue; } @@ -159,7 +159,7 @@ void RealmList::UpdateRealms(boost::system::error_code const& error) endPoint = _resolver->resolve(localSubmaskQuery, ec); if (endPoint == end || ec) { - TC_LOG_ERROR("server.authserver", "Could not resolve address %s", fields[4].GetString().c_str()); + TC_LOG_ERROR("server.bnetserver", "Could not resolve address %s", fields[4].GetString().c_str()); continue; } @@ -181,11 +181,11 @@ void RealmList::UpdateRealms(boost::system::error_code const& error) UpdateRealm(id, name, externalAddress, localAddress, localSubmask, port, icon, flag, timezone, (allowedSecurityLevel <= SEC_ADMINISTRATOR ? AccountTypes(allowedSecurityLevel) : SEC_ADMINISTRATOR), pop); - //TC_LOG_INFO("server.authserver", "Added realm \"%s\" at %s:%u.", name.c_str(), m_realms[id].ExternalAddress.to_string().c_str(), port); + //TC_LOG_INFO("server.bnetserver", "Added realm \"%s\" at %s:%u.", name.c_str(), m_realms[id].ExternalAddress.to_string().c_str(), port); } catch (std::exception& ex) { - TC_LOG_ERROR("server.authserver", "Realmlist::UpdateRealms has thrown an exception: %s", ex.what()); + TC_LOG_ERROR("server.bnetserver", "Realmlist::UpdateRealms has thrown an exception: %s", ex.what()); ASSERT(false); } } |