Skip to content

Commit

Permalink
free instead of delete
Browse files Browse the repository at this point in the history
  • Loading branch information
cheat-engine committed Feb 19, 2022
1 parent b30bc69 commit cb4db2f
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions Cheat Engine/MainUnit.pas
Original file line number Diff line number Diff line change
Expand Up @@ -4196,7 +4196,7 @@ procedure TMainForm.UpdateMenu;
while miTable.Count > 5 do
begin
if miTable.Items[4] <> miLuaFormsSeperator then
miTable.Delete(4)
miTable[4].Free
else
break;
end;
Expand Down Expand Up @@ -4259,7 +4259,7 @@ procedure TMainForm.UpdateMenu;

//and now the files
while miTable.Count > miTable.indexOf(miAddFile) + 1 do
miTable.Delete(miTable.indexOf(miAddFile) + 1);
miTable[miTable.indexOf(miAddFile) + 1].free;

for i := 0 to luafiles.Count - 1 do
begin
Expand Down

0 comments on commit cb4db2f

Please sign in to comment.