diff --git a/content/base/src/nsTextNode.cpp b/content/base/src/nsTextNode.cpp index 7d48e41acb2..077ecde84e0 100644 --- a/content/base/src/nsTextNode.cpp +++ b/content/base/src/nsTextNode.cpp @@ -112,6 +112,7 @@ public: PRBool aNullParent = PR_TRUE); NS_DECL_NSIMUTATIONOBSERVER_ATTRIBUTECHANGED + NS_DECL_NSIMUTATIONOBSERVER_NODEWILLBEDESTROYED virtual nsGenericDOMDataNode *CloneDataNode(nsINodeInfo *aNodeInfo, PRBool aCloneText) const @@ -358,6 +359,13 @@ nsAttributeTextNode::AttributeChanged(nsIDocument* aDocument, } } +void +nsAttributeTextNode::NodeWillBeDestroyed(const nsINode* aNode) +{ + NS_ASSERTION(aNode == static_cast(mGrandparent), "Wrong node!"); + mGrandparent = nsnull; +} + void nsAttributeTextNode::UpdateText(PRBool aNotify) {