mirror of
https://github.com/TES3MP/TES3MP.git
synced 2025-09-28 07:32:00 -04:00
Fix server crash caused by invalid player GUIDs
This commit is contained in:
parent
937bf97883
commit
3c88f6f0cd
@ -707,6 +707,9 @@ void Networking::NewPlayer(RakNet::RakNetGUID guid)
|
|||||||
// If we are iterating over the new player, don't send the packets below
|
// If we are iterating over the new player, don't send the packets below
|
||||||
if (pl->first == guid.g) continue;
|
if (pl->first == guid.g) continue;
|
||||||
|
|
||||||
|
// If an invalid key makes it into the Players map, ignore it
|
||||||
|
else if (pl->first == RakNet::UNASSIGNED_NETWORK_ID) continue;
|
||||||
|
|
||||||
playerController->GetPacket(ID_GAME_BASE_INFO)->Send(pl->second, guid);
|
playerController->GetPacket(ID_GAME_BASE_INFO)->Send(pl->second, guid);
|
||||||
playerController->GetPacket(ID_GAME_DYNAMICSTATS)->Send(pl->second, guid);
|
playerController->GetPacket(ID_GAME_DYNAMICSTATS)->Send(pl->second, guid);
|
||||||
playerController->GetPacket(ID_GAME_ATTRIBUTE)->Send(pl->second, guid);
|
playerController->GetPacket(ID_GAME_ATTRIBUTE)->Send(pl->second, guid);
|
||||||
|
Loading…
x
Reference in New Issue
Block a user