View Issue Details

IDProjectCategoryView StatusLast Update
0003215JEDI VCL00 JVCL Componentspublic2006-04-05 01:16
ReporterpawelgoluchAssigned Toobones 
Status resolvedResolutionfixed 
Product Version3.00 
Target VersionFixed in Version3.30 
Summary0003215: TJvDBCustomSearchComboBox Bookmarks memory leak
Description      while not EOF do
        Items.AddObject(FieldByName(FDataLink.FDataFieldName).DisplayText, GetBookmark);
        if Bookmark = Bmrk then
          CurIndex := N;

I think that in function ReadList we've got memory leak during call GetBookmark function (see above). In the example below there is a memory leak (see comments)

 TExampleFrame = class(TFrame)
   ComboBox: TJvDBSearchComboBox;

{$R *.dfm}

procedure TForm1.Button1Click(Sender: TObject);
 DataModule: TDataM;
 Frame: TExampleFrame;
 DataModule:= TDataM.Create(Application);
 Frame:= TExampleFrame.Create(PageList.Pages[0]{example owner});

 Frame.ComboBox.DataSource:= DataModule.TypesSource;
 Frame.ComboBox.DataField:= 'Type';

 Frame.Parent:= PageList.Pages[0];
 Frame.Free; //In that configuration there is
 DataModule.Free; //a memory leak
// DataModule.Free; and in that configuration
// Frame.Free; there isn't memory leak
TagsNo tags attached.



2006-04-04 02:41

administrator   ~0008852

A call to clearlist has been added in the destructor, this should solve this problem. It will be added to CVS as soon as the system is back online.


2006-04-05 01:16

administrator   ~0008921

This is now in CVS

Issue History

Date Modified Username Field Change
2005-09-22 06:42 pawelgoluch New Issue
2006-04-04 02:41 obones Note Added: 0008852
2006-04-04 02:41 obones Status new => confirmed
2006-04-05 01:16 obones Status confirmed => resolved
2006-04-05 01:16 obones Resolution open => fixed
2006-04-05 01:16 obones Assigned To => obones
2006-04-05 01:16 obones Note Added: 0008921