Fixed server crash when disconnecting during login.

This commit is contained in:
lotodore
2010-09-04 16:43:30 +00:00
parent 17f10632e3
commit 7d145bf0e1
+6 -3
View File
@@ -1558,9 +1558,12 @@ void
ServerLobbyThread::UserValid(unsigned playerId, const DBPlayerData &dbPlayerData)
{
SessionWrapper tmpSession = m_sessionManager.GetSessionByUniquePlayerId(playerId, true);
tmpSession.playerData->SetDBId(dbPlayerData.id);
tmpSession.playerData->SetCountry(dbPlayerData.country);
this->AuthChallenge(tmpSession, dbPlayerData.secret);
if (tmpSession.sessionData && tmpSession.playerData)
{
tmpSession.playerData->SetDBId(dbPlayerData.id);
tmpSession.playerData->SetCountry(dbPlayerData.country);
this->AuthChallenge(tmpSession, dbPlayerData.secret);
}
}
void