mirror of
https://gitlab.com/freepascal.org/lazarus/lazarus.git
synced 2025-08-09 02:36:07 +02:00
fixed memleak on published var completion from Vincent
git-svn-id: trunk@4998 -
This commit is contained in:
parent
7c8f973a48
commit
37a33a8594
@ -548,6 +548,7 @@ var
|
||||
CleanMethodDefinition, MethodDefinition: string;
|
||||
FindContext: TFindContext;
|
||||
begin
|
||||
try
|
||||
Result:=false;
|
||||
if (ClassNode=nil) or (ClassNode.Desc<>ctnClass) or (AMethodName='')
|
||||
or (ATypeInfo=nil) or (SourceChangeCache=nil) or (Scanner=nil) then exit;
|
||||
@ -598,6 +599,9 @@ begin
|
||||
writeln('[TEventsCodeTool.CreatePublishedMethod] END');
|
||||
{$ENDIF}
|
||||
Result:=true;
|
||||
finally
|
||||
FreeClassInsertionList;
|
||||
end;
|
||||
end;
|
||||
|
||||
function TEventsCodeTool.CreateExprListFromMethodTypeData(
|
||||
@ -720,6 +724,7 @@ var
|
||||
UpperCurComponentName: String;
|
||||
VarType: String;
|
||||
begin
|
||||
try
|
||||
Result:=false;
|
||||
BuildTree(false);
|
||||
if not EndOfSourceFound then exit;
|
||||
@ -767,6 +772,9 @@ begin
|
||||
writeln('[TEventsCodeTool.CompleteComponent] END');
|
||||
{ $ENDIF}
|
||||
Result:=true;
|
||||
finally
|
||||
FreeClassInsertionList;
|
||||
end;
|
||||
end;
|
||||
|
||||
function TEventsCodeTool.FindIdentifierNodeInClass(ClassNode: TCodeTreeNode;
|
||||
|
Loading…
Reference in New Issue
Block a user