diff options
Diffstat (limited to 'src/game/Server/WorldSocket.cpp')
-rw-r--r-- | src/game/Server/WorldSocket.cpp | 35 |
1 files changed, 20 insertions, 15 deletions
diff --git a/src/game/Server/WorldSocket.cpp b/src/game/Server/WorldSocket.cpp index bae62d44c1..f0ebcb90ee 100644 --- a/src/game/Server/WorldSocket.cpp +++ b/src/game/Server/WorldSocket.cpp @@ -282,14 +282,18 @@ int WorldSocket::handle_input (ACE_HANDLE) return Update(); // interesting line, isn't it ? } - ;//sLog->outStaticDebug("WorldSocket::handle_input: Peer error closing connection errno = %s", ACE_OS::strerror (errno)); +#if defined(ENABLE_EXTRAS) && defined(ENABLE_EXTRA_LOGS) + sLog->outStaticDebug("WorldSocket::handle_input: Peer error closing connection errno = %s", ACE_OS::strerror (errno)); +#endif errno = ECONNRESET; return -1; } case 0: { - ;//sLog->outStaticDebug("WorldSocket::handle_input: Peer has closed connection"); +#if defined(ENABLE_EXTRAS) && defined(ENABLE_EXTRA_LOGS) + sLog->outStaticDebug("WorldSocket::handle_input: Peer has closed connection"); +#endif errno = ECONNRESET; return -1; @@ -752,13 +756,9 @@ int WorldSocket::HandleAuthSession(WorldPacket& recvPacket) recvPacket >> unk4; recvPacket.read(digest, 20); - ;//sLog->outStaticDebug ("WorldSocket::HandleAuthSession: client %u, unk2 %u, account %s, unk3 %u, clientseed %u", - // BuiltNumberClient, - // unk2, - // account.c_str(), - // unk3, - // clientSeed); - +#if defined(ENABLE_EXTRAS) && defined(ENABLE_EXTRA_LOGS) + sLog->outStaticDebug ("WorldSocket::HandleAuthSession: client %u, unk2 %u, account %s, unk3 %u, clientseed %u", BuiltNumberClient, unk2, account.c_str(), unk3, clientSeed); +#endif // Get the account information from the realmd database // 0 1 2 3 4 5 6 7 8 // SELECT id, sessionkey, last_ip, locked, expansion, mutetime, locale, recruiter, os FROM account WHERE username = ? @@ -878,7 +878,9 @@ int WorldSocket::HandleAuthSession(WorldPacket& recvPacket) // Check locked state for server AccountTypes allowedAccountType = sWorld->GetPlayerSecurityLimit(); - ;//sLog->outDebug(LOG_FILTER_NETWORKIO, "Allowed Level: %u Player Level %u", allowedAccountType, AccountTypes(security)); +#if defined(ENABLE_EXTRAS) && defined(ENABLE_EXTRA_LOGS) + sLog->outDebug(LOG_FILTER_NETWORKIO, "Allowed Level: %u Player Level %u", allowedAccountType, AccountTypes(security)); +#endif if (AccountTypes(security) < allowedAccountType) { WorldPacket Packet (SMSG_AUTH_RESPONSE, 1); @@ -886,7 +888,9 @@ int WorldSocket::HandleAuthSession(WorldPacket& recvPacket) SendPacket(packet); - ;//sLog->outDetail("WorldSocket::HandleAuthSession: User tries to login but his security level is not enough"); +#if defined(ENABLE_EXTRAS) && defined(ENABLE_EXTRA_LOGS) + sLog->outDetail("WorldSocket::HandleAuthSession: User tries to login but his security level is not enough"); +#endif return -1; } @@ -914,10 +918,11 @@ int WorldSocket::HandleAuthSession(WorldPacket& recvPacket) return -1; } - ;//sLog->outStaticDebug("WorldSocket::HandleAuthSession: Client '%s' authenticated successfully from %s.", - // account.c_str(), - // address.c_str()); - +#if defined(ENABLE_EXTRAS) && defined(ENABLE_EXTRA_LOGS) + sLog->outStaticDebug("WorldSocket::HandleAuthSession: Client '%s' authenticated successfully from %s.", + account.c_str(), + address.c_str()); +#endif // Check if this user is by any chance a recruiter stmt = LoginDatabase.GetPreparedStatement(LOGIN_SEL_ACCOUNT_RECRUITER); |