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

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

Issue 2258873004: Leak Detector: Count ScriptPromise and ActiveDOMObject on worker threads (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Bug fix: Build fail on ChromeOS Created 4 years, 4 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/ActiveDOMObject.cpp
diff --git a/third_party/WebKit/Source/core/dom/ActiveDOMObject.cpp b/third_party/WebKit/Source/core/dom/ActiveDOMObject.cpp
index d84207e399f5a98c1aabecb3efd12b87b9328ed3..8c06cae54058b9f3b10d26854a5ff5cc350911d7 100644
--- a/third_party/WebKit/Source/core/dom/ActiveDOMObject.cpp
+++ b/third_party/WebKit/Source/core/dom/ActiveDOMObject.cpp
@@ -38,17 +38,12 @@ ActiveDOMObject::ActiveDOMObject(ExecutionContext* executionContext)
#endif
{
DCHECK(!executionContext || executionContext->isContextThread());
- // TODO(hajimehoshi): Now the leak detector can't treat vaious threads other
- // than the main thread and worker threads. After fixing the leak detector,
- // let's count objects on other threads as many as possible.
- if (isMainThread())
- InstanceCounters::incrementCounter(InstanceCounters::ActiveDOMObjectCounter);
+ InstanceCounters::incrementCounter(InstanceCounters::ActiveDOMObjectCounter);
}
ActiveDOMObject::~ActiveDOMObject()
{
- if (isMainThread())
- InstanceCounters::decrementCounter(InstanceCounters::ActiveDOMObjectCounter);
+ InstanceCounters::decrementCounter(InstanceCounters::ActiveDOMObjectCounter);
#if DCHECK_IS_ON()
DCHECK(m_suspendIfNeededCalled);

Powered by Google App Engine
This is Rietveld 408576698