<html><head><meta http-equiv="Content-Type" content="text/html; charset=UTF-8" /></head><body style='font-size: 10pt; font-family: Arial,Helvetica,sans-serif'>
<div>All of a sudden I get a crash in my app trying to read a path from an XML file. The crash comes from the function TDOMNamedNodeMap.Find that crashes on this line: <br /><br />C := TDOMNode(FList.List^[I]).CompareName(name);<br /><br />The strange thing is that a simplified example app does not crash! In any case I'm 100% sure the path exists and either way even if it didn't XMLConfig should not crash. The message form the lazarus code inspector is: Type TDOMNODE has no component named COMPARENAME.The code also never reaches the CompareName function when I set a breakpoint.<br /><br />I'm at a loss. Is any one capable to understand what is happening?<br /><br />Rgds, Darius<br /><br /><br />My code is:<br /><br /> c := cache.GetValue('filelist/item_1/crc', 0);<br /><br />The XML is:<br /><br /><?xml version="1.0" encoding="utf-8"?><br /><CONFIG><br /> <filelist type="filecache" count="1"><br /> <item_1 crc="30150" filename="C:\myfile.txt"/><br /> </filelist><br /></CONFIG><br /><br />The BT is:<br /><br />An unhandled exception occurred at $0000000100033BA4:<br />EAccessViolation: Access violation<br /> $0000000100033BA4 line 1783 of fcl-xml/src/dom.pp<br /> $0000000100033C75 line 1802 of fcl-xml/src/dom.pp<br /> $000000010003707D line 3159 of fcl-xml/src/dom.pp<br /> $000000010002EC28 line 195 of xmlconf.pp</div>
</body></html>