BUG: General protection fault when you make changes to XML nodes (824192)
The information in this article applies to:
- Microsoft Internet Explorer (Programming) 6 (SP1)
- Microsoft XML 2.0
- Microsoft XML 2.5
- Microsoft XML 2.6
- Microsoft XML 3.0
- Microsoft XML 4.0
SYMPTOMSWhen you make a change to an XML node directly in an XMLHTTP application, you receive the following general protection fault (GP fault) error message: The instruction at <memoryaddress> referenced memory at <memoryaddress>. The memory could not be "read". Note<memoryaddress> is the placeholder for the respective memory address. CAUSEWhen an event is raised in an XMLHTTP application, the Mshtml.dll file may destroy a node to replace the node during XML node manipulation in the event handler. Other statements may exist in the event handler in an Internet Explorer message loop that may access the XML node directly for manipulation.
When the node is accessed directly, a GP fault occurs because it accesses a node that no longer exists. The node was moved by the Mshtml.dll file.WORKAROUNDTo work around this problem, avoid direct access of the node in the event handler, and include a process timer to fire the manipulation code after a short delay of 100 milliseconds. For example, if the original call that changes the nodes is the MoveNode(item) function, create a worker function that is named MoveNode_Worker(item), and then move the code that actually handles the manipulation of the nodes to the MoveNode_Worker(item) function.
In the MoveNode() function, call the MoveNode_Worker(item) worker thread after 100 milliseconds by using the window.setInterval() function function. interval = window.setInterval("MoveNode_Worker(item)",100); STATUSMicrosoft has confirmed that this is a bug in the Microsoft products that are listed in the "Applies to" section of this article.REFERENCES
For additional information, click the following article number to view the article in the Microsoft Knowledge Base:
288913
HOWTO: Use XPath queries in MSXML DOM selectNodes method
Modification Type: | Major | Last Reviewed: | 3/13/2004 |
---|
Keywords: | kbhtml kbXML kbbug KB824192 kbAudDeveloper |
---|
|