Skip to content

Commit

Permalink
Remove not needed code in HandleAuthSession (#2535)
Browse files Browse the repository at this point in the history
  • Loading branch information
shudza authored Mar 4, 2024
1 parent fa09f08 commit a66a644
Showing 1 changed file with 1 addition and 20 deletions.
21 changes: 1 addition & 20 deletions src/game/Protocol/WorldSocket.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -143,7 +143,7 @@ int WorldSocket::HandleAuthSession(WorldPacket& recvPacket)
uint32 id, security;
LocaleConstant locale;
std::string account, os, platform;
BigNumber v, s, g, N, K;
BigNumber K;
WorldPacket packet, addonPacket;
static std::set<std::string> const serverAddressList = GetServerAddresses();

Expand Down Expand Up @@ -196,22 +196,6 @@ int WorldSocket::HandleAuthSession(WorldPacket& recvPacket)

Field* fields = result->Fetch();

N.SetHexStr("894B645E89E1535BBDAD5B8B290650530801B18EBFBF5E8FAB3C82872A3E9BB7");
g.SetDword(7);

v.SetHexStr(fields[4].GetString());
s.SetHexStr(fields[5].GetString());

char const* sStr = s.AsHexStr(); //Must be freed by OPENSSL_free()
char const* vStr = v.AsHexStr(); //Must be freed by OPENSSL_free()

sLog.Out(LOG_BASIC, LOG_LVL_DEBUG, "WorldSocket::HandleAuthSession: (s,v) check s: %s v: %s",
sStr,
vStr);

OPENSSL_free((void*) sStr);
OPENSSL_free((void*) vStr);

// Prevent connecting directly to mangosd by checking
// that same ip connected to realmd previously.
if (strcmp(fields[3].GetString(), GetRemoteAddress().c_str()) &&
Expand Down Expand Up @@ -341,9 +325,6 @@ int WorldSocket::HandleAuthSession(WorldPacket& recvPacket)
m_Session->LoadGlobalAccountData();
m_Session->LoadTutorialsData();

// In case needed sometime the second arg is in microseconds 1 000 000 = 1 sec
ACE_OS::sleep(ACE_Time_Value(0, 10000));

sWorld.AddSession(m_Session);

// Create and send the Addon packet
Expand Down

0 comments on commit a66a644

Please sign in to comment.