mirror of
https://gitlab.com/freepascal.org/lazarus/lazarus.git
synced 2025-04-23 15:39:49 +02:00
Jedi code format: Fix memory leak.
This commit is contained in:
parent
27d50a74a8
commit
8a98df0369
@ -112,7 +112,7 @@ uses
|
||||
constructor TSourceTokenList.Create;
|
||||
begin
|
||||
fiCurrentTokenIndex := 0;
|
||||
OwnsObjects := True;
|
||||
OwnsObjects := False;
|
||||
inherited Create(False);
|
||||
end;
|
||||
|
||||
|
@ -191,6 +191,7 @@ begin
|
||||
{ if there was a parse error, the rest of the unit was not parsed
|
||||
there may still be tokens in the list
|
||||
Free them or face a small but annoying memory leak. }
|
||||
lcTokenList.OwnsObjects := True;
|
||||
lcTokenList.Clear;
|
||||
end;
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user