Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(288)

Unified Diff: third_party/WebKit/Source/core/dom/Node.cpp

Issue 1962953002: Storage of ComputedStyle separate from LayoutObject. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Addressed reviewer comments Created 4 years, 6 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: third_party/WebKit/Source/core/dom/Node.cpp
diff --git a/third_party/WebKit/Source/core/dom/Node.cpp b/third_party/WebKit/Source/core/dom/Node.cpp
index a7f51f704a679c10db793f474762e3b0348a759a..05c46885aaf4cdb93e1e66d8884aca7f60ca1241 100644
--- a/third_party/WebKit/Source/core/dom/Node.cpp
+++ b/third_party/WebKit/Source/core/dom/Node.cpp
@@ -263,6 +263,8 @@ Node::~Node()
// this condition (we cannot directly access it here.)
RELEASE_ASSERT(hasRareData() || !layoutObject());
InstanceCounters::decrementCounter(InstanceCounters::NodeCounter);
+ if (!hasRareData() && !hasLayoutObject() && m_data.m_computedStyle)
+ m_data.m_computedStyle->deref();
}
NodeRareData* Node::rareData() const

Powered by Google App Engine
This is Rietveld 408576698