ide: fix a memory leak I made in TSourceEditor.OnGutterClick

git-svn-id: trunk@18964 -
This commit is contained in:
paul 2009-03-12 03:39:56 +00:00
parent 0ecf4167d0
commit 09b40cf1b1

View File

@ -2088,6 +2088,8 @@ var
begin
// create or delete breakpoint
// find breakpoint mark at line
Marks := nil;
try
SourceEditorMarks.GetMarksForLine(FEditor, Line, Marks, MarkCount);
BreakFound := False;
ExecutionFound := False;
@ -2104,6 +2106,9 @@ begin
if Marks[i] = FExecutionMark then
ExecutionFound := True;
end;
finally
FreeMem(Marks);
end;
if not BreakFound then
DebugBoss.DoCreateBreakPoint(Filename, Line, True);