summaryrefslogtreecommitdiffstats
path: root/Source/WebCore/dom/Document.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'Source/WebCore/dom/Document.cpp')
-rw-r--r--Source/WebCore/dom/Document.cpp9
1 files changed, 9 insertions, 0 deletions
diff --git a/Source/WebCore/dom/Document.cpp b/Source/WebCore/dom/Document.cpp
index 60ecdb9..f319cac 100644
--- a/Source/WebCore/dom/Document.cpp
+++ b/Source/WebCore/dom/Document.cpp
@@ -110,6 +110,7 @@
#include "NestingLevelIncrementer.h"
#include "NodeFilter.h"
#include "NodeIterator.h"
+#include "NodeRareData.h"
#include "NodeWithIndex.h"
#include "OverflowEvent.h"
#include "Page.h"
@@ -424,6 +425,7 @@ Document::Document(Frame* frame, const KURL& url, bool isXHTML, bool isHTML)
, m_sawElementsInKnownNamespaces(false)
, m_usingGeolocation(false)
, m_eventQueue(EventQueue::create(this))
+ , m_documentRareData(0)
#if ENABLE(WML)
, m_containsWMLContent(false)
#endif
@@ -573,6 +575,13 @@ Document::~Document()
if (m_implementation)
m_implementation->ownerDocumentDestroyed();
+
+ if (hasRareData()) {
+ ASSERT(m_documentRareData);
+ delete m_documentRareData;
+ m_documentRareData = 0;
+ clearFlag(HasRareDataFlag);
+ }
}
void Document::removedLastRef()