fixed memleak on published var completion from Vincent

git-svn-id: trunk@4998 -
This commit is contained in:
mattias 2004-01-03 12:17:25 +00:00
parent 7c8f973a48
commit 37a33a8594

View File

@ -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;