View Issue Details

IDProjectCategoryView StatusLast Update
0001911JEDI VCL00 JVCL Componentspublic2004-08-02 12:25
ReporteranonymousAssigned Toobones 
PrioritynormalSeverityminorReproducibilityalways
Status resolvedResolutionfixed 
Product Version3.00 BETA 
Target VersionFixed in Version 
Summary0001911: TJvSimpleXML, TJvSimpleXMLElems
DescriptionThis method
    function Add(Value: TJvSimpleXMLElem): TJvSimpleXMLElem; overload;

is dangerous, because you can add node from another TJvSimpleXML component and its causes crash in Clear method

(after add node you free memory twice).
TagsNo tags attached.

Activities

obones

2004-07-05 23:19

administrator   ~0004695

What should we do?
Create a new TJvSimpleXMLElem and assign Value to it or leave the method as it is now and add a parameter to select wether or not to copy (defaulting to not in order to keep the old behaviour)

anonymous

2004-07-06 23:54

viewer   ~0004709

Maybe you should check what is the pointer of added TJvSimpleXMLElem parent component and raise exception if is diffrent then current pointer. It's possible ?

obones

2004-08-02 12:25

administrator   ~0004870

I introduced a Notify concept so that a TJvSimpleXMLElems knows when an element is added in another one and prevent "double free"

Issue History

Date Modified Username Field Change
2004-07-01 03:14 anonymous New Issue
2004-07-05 00:33 obones Status new => assigned
2004-07-05 00:33 obones Assigned To => obones
2004-07-05 23:19 obones Note Added: 0004695
2004-07-06 23:54 anonymous Note Added: 0004709
2004-08-02 12:25 obones Status assigned => resolved
2004-08-02 12:25 obones Resolution open => fixed
2004-08-02 12:25 obones Note Added: 0004870