* Correctly free objects when destroying stringlist instance

git-svn-id: trunk@20265 -
This commit is contained in:
michael 2012-02-05 19:55:21 +00:00
parent b058593b53
commit 723482c814

View File

@ -1133,10 +1133,7 @@ Var I : Longint;
begin begin
FOnChange:=Nil; FOnChange:=Nil;
FOnChanging:=Nil; FOnChanging:=Nil;
// This will force a dereference. Can be done better... Clear;
For I:=0 to FCount-1 do
FList^[I].FString:='';
FCount:=0;
SetCapacity(0); SetCapacity(0);
Inherited destroy; Inherited destroy;
end; end;