Fix possible memory corruption in `TArray::Delete(index, count)`

This commit is contained in:
Ricardo Luís Vaz Silva 2023-03-22 04:54:29 -03:00 committed by Christoph Oelckers
parent c041b437e1
commit 9e19134016
1 changed files with 2 additions and 0 deletions

View File

@ -453,6 +453,8 @@ public:
void Delete (unsigned int index, int deletecount)
{
if(index >= Count) return;
if (index + deletecount > Count)
{
deletecount = Count - index;