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

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

Issue 1854423002: ASSERT -> {DCHECK|DCHECK_XX}, ENABLE(ASSERT) -> DCHECK_IS_ON() in dom (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: mark svg/as-image/svg-nested.html crash on win Created 4 years, 8 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/ExecutionContext.cpp
diff --git a/third_party/WebKit/Source/core/dom/ExecutionContext.cpp b/third_party/WebKit/Source/core/dom/ExecutionContext.cpp
index a190bcd84b65555f3a930c0c1d95ee16ebf591c1..66cff47414448e2d1cffcebad1a08e0065b72c34 100644
--- a/third_party/WebKit/Source/core/dom/ExecutionContext.cpp
+++ b/third_party/WebKit/Source/core/dom/ExecutionContext.cpp
@@ -78,14 +78,14 @@ ExecutionContext::~ExecutionContext()
void ExecutionContext::suspendActiveDOMObjects()
{
- ASSERT(!m_activeDOMObjectsAreSuspended);
+ DCHECK(!m_activeDOMObjectsAreSuspended);
notifySuspendingActiveDOMObjects();
m_activeDOMObjectsAreSuspended = true;
}
void ExecutionContext::resumeActiveDOMObjects()
{
- ASSERT(m_activeDOMObjectsAreSuspended);
+ DCHECK(m_activeDOMObjectsAreSuspended);
m_activeDOMObjectsAreSuspended = false;
notifyResumingActiveDOMObjects();
}
@@ -131,7 +131,9 @@ void ExecutionContext::resumeScheduledTasks()
void ExecutionContext::suspendActiveDOMObjectIfNeeded(ActiveDOMObject* object)
{
- ASSERT(contains(object));
+#if DCHECK_IS_ON()
+ DCHECK(contains(object));
+#endif
// Ensure all ActiveDOMObjects are suspended also newly created ones.
if (m_activeDOMObjectsAreSuspended)
object->suspend();
@@ -178,7 +180,7 @@ bool ExecutionContext::dispatchErrorEvent(RawPtr<ErrorEvent> event, AccessContro
if (shouldSanitizeScriptError(errorEvent->filename(), corsStatus))
errorEvent = ErrorEvent::createSanitizedError(errorEvent->world());
- ASSERT(!m_inDispatchErrorEvent);
+ DCHECK(!m_inDispatchErrorEvent);
m_inDispatchErrorEvent = true;
target->dispatchEvent(errorEvent);
m_inDispatchErrorEvent = false;
« no previous file with comments | « third_party/WebKit/Source/core/dom/ElementTest.cpp ('k') | third_party/WebKit/Source/core/dom/FirstLetterPseudoElement.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698