[Crash] Fix out of bound arrays, other potential crashes (#3166)

This commit is contained in:
Aeadoin
2023-04-01 12:44:41 -04:00
committed by GitHub
parent 0d509a7f3a
commit 0df84e1ee6
9 changed files with 34 additions and 24 deletions
+2 -2
View File
@@ -631,7 +631,7 @@ uint32 Raid::GetPlayerIndex(Client *c)
Client *Raid::GetClientByIndex(uint16 index)
{
if (index > MAX_RAID_MEMBERS) {
if (index >= MAX_RAID_MEMBERS) {
return nullptr;
}
@@ -2204,4 +2204,4 @@ void Raid::SetNewRaidLeader(uint32 i)
}
}
}
}
}