View Issue Details
ID | Project | Category | View Status | Date Submitted | Last Update |
---|---|---|---|---|---|
0003093 | JEDI VCL | 00 JVCL Components | public | 2005-07-15 07:41 | 2005-08-09 06:50 |
Reporter | anonymous | Assigned To | outchy | ||
Priority | normal | Severity | major | Reproducibility | always |
Status | resolved | Resolution | fixed | ||
Product Version | 3.00 | ||||
Target Version | Fixed in Version | 3.10 | |||
Summary | 0003093: JvHTMLParser | ||||
Description | It seems that there is a memory leak in the JvHTMLParser. The FKeys stringlist is assigned a TParserInfo Object. However, there are several locations where the elements of the FKeys are cleared or deleted or freed (Destroy event) and the associated objects aren't freed. | ||||
Additional Information | I've made the following changes to my source and include them here for your reference. destructor TJvHTMLParser.Destroy; var i: Integer; begin FParser.Free; //Free associated objects prior to clearing the list for i := 0 to FKeys.Count - 1 do FKeys.Objects[i].Free; FKeys.Free; <snip> end; procedure TJvHTMLParser.SetParser(Value: TStrings); var I: Integer; Obj: TJvParserInfo; Cap: string; begin if FParser <> Value then // make sure we don't assign to ourselves (that will clear the list) FParser.Assign(Value); //Free associated objects prior to clearing the list for i := 0 to FKeys.Count - 1 do FKeys.Objects[i].Free; FKeys.Clear; I := 0; <snip> procedure TJvHTMLParser.RemoveCondition(Index: Integer); begin //Free associated objects prior to clearing the list FKeys.Objects[Index].Free; FKeys.Delete(Index); end; procedure TJvHTMLParser.ClearConditions; var i: Integer; begin FParser.Clear; //Free associated objects prior to clearing the list for i := 0 to FKeys.Count - 1 do FKeys.Objects[i].Free; FKeys.Clear; end; These changes seem to remove the memory leaks. | ||||
Tags | No tags attached. | ||||
Date Modified | Username | Field | Change |
---|---|---|---|
2005-07-15 07:41 | anonymous | New Issue | |
2005-07-19 13:26 | outchy | Note Added: 0007571 | |
2005-07-19 13:26 | outchy | Status | new => confirmed |
2005-07-19 13:37 | outchy | Status | confirmed => feedback |
2005-08-09 06:42 | obones | Note Added: 0007713 | |
2005-08-09 06:50 | outchy | Status | feedback => resolved |
2005-08-09 06:50 | outchy | Resolution | open => fixed |
2005-08-09 06:50 | outchy | Assigned To | => outchy |
2005-08-09 06:50 | outchy | Note Added: 0007714 |