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

Unified Diff: third_party/WebKit/Source/bindings/tests/results/core/V8TestCallbackInterface.cpp

Issue 2800093002: DCHECK for execution context being unsuspended during v8 bindings callback. (Closed)
Patch Set: Rebased Created 3 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
« no previous file with comments | « third_party/WebKit/Source/bindings/templates/callback_interface.cpp.tmpl ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: third_party/WebKit/Source/bindings/tests/results/core/V8TestCallbackInterface.cpp
diff --git a/third_party/WebKit/Source/bindings/tests/results/core/V8TestCallbackInterface.cpp b/third_party/WebKit/Source/bindings/tests/results/core/V8TestCallbackInterface.cpp
index 7435cec9f85dfd9c5f1405a331959df30cfc716d..69ea2fa20f7a8e5fd8e620730fda013e74084847 100644
--- a/third_party/WebKit/Source/bindings/tests/results/core/V8TestCallbackInterface.cpp
+++ b/third_party/WebKit/Source/bindings/tests/results/core/V8TestCallbackInterface.cpp
@@ -37,8 +37,8 @@ DEFINE_TRACE(V8TestCallbackInterface) {
void V8TestCallbackInterface::voidMethod() {
ExecutionContext* executionContext =
ExecutionContext::From(m_scriptState.Get());
- if (!executionContext || executionContext->IsContextSuspended() ||
- executionContext->IsContextDestroyed())
+ DCHECK(!executionContext->IsContextSuspended());
+ if (!executionContext || executionContext->IsContextDestroyed())
return;
if (!m_scriptState->ContextIsValid())
return;
@@ -59,8 +59,8 @@ void V8TestCallbackInterface::voidMethod() {
bool V8TestCallbackInterface::booleanMethod() {
ExecutionContext* executionContext =
ExecutionContext::From(m_scriptState.Get());
- if (!executionContext || executionContext->IsContextSuspended() ||
- executionContext->IsContextDestroyed())
+ DCHECK(!executionContext->IsContextSuspended());
+ if (!executionContext || executionContext->IsContextDestroyed())
return true;
if (!m_scriptState->ContextIsValid())
return true;
@@ -84,8 +84,8 @@ bool V8TestCallbackInterface::booleanMethod() {
void V8TestCallbackInterface::voidMethodBooleanArg(bool boolArg) {
ExecutionContext* executionContext =
ExecutionContext::From(m_scriptState.Get());
- if (!executionContext || executionContext->IsContextSuspended() ||
- executionContext->IsContextDestroyed())
+ DCHECK(!executionContext->IsContextSuspended());
+ if (!executionContext || executionContext->IsContextDestroyed())
return;
if (!m_scriptState->ContextIsValid())
return;
@@ -107,8 +107,8 @@ void V8TestCallbackInterface::voidMethodBooleanArg(bool boolArg) {
void V8TestCallbackInterface::voidMethodSequenceArg(const HeapVector<Member<TestInterfaceEmpty>>& sequenceArg) {
ExecutionContext* executionContext =
ExecutionContext::From(m_scriptState.Get());
- if (!executionContext || executionContext->IsContextSuspended() ||
- executionContext->IsContextDestroyed())
+ DCHECK(!executionContext->IsContextSuspended());
+ if (!executionContext || executionContext->IsContextDestroyed())
return;
if (!m_scriptState->ContextIsValid())
return;
@@ -130,8 +130,8 @@ void V8TestCallbackInterface::voidMethodSequenceArg(const HeapVector<Member<Test
void V8TestCallbackInterface::voidMethodFloatArg(float floatArg) {
ExecutionContext* executionContext =
ExecutionContext::From(m_scriptState.Get());
- if (!executionContext || executionContext->IsContextSuspended() ||
- executionContext->IsContextDestroyed())
+ DCHECK(!executionContext->IsContextSuspended());
+ if (!executionContext || executionContext->IsContextDestroyed())
return;
if (!m_scriptState->ContextIsValid())
return;
@@ -153,8 +153,8 @@ void V8TestCallbackInterface::voidMethodFloatArg(float floatArg) {
void V8TestCallbackInterface::voidMethodTestInterfaceEmptyArg(TestInterfaceEmpty* testInterfaceEmptyArg) {
ExecutionContext* executionContext =
ExecutionContext::From(m_scriptState.Get());
- if (!executionContext || executionContext->IsContextSuspended() ||
- executionContext->IsContextDestroyed())
+ DCHECK(!executionContext->IsContextSuspended());
+ if (!executionContext || executionContext->IsContextDestroyed())
return;
if (!m_scriptState->ContextIsValid())
return;
@@ -176,8 +176,8 @@ void V8TestCallbackInterface::voidMethodTestInterfaceEmptyArg(TestInterfaceEmpty
void V8TestCallbackInterface::voidMethodTestInterfaceEmptyStringArg(TestInterfaceEmpty* testInterfaceEmptyArg, const String& stringArg) {
ExecutionContext* executionContext =
ExecutionContext::From(m_scriptState.Get());
- if (!executionContext || executionContext->IsContextSuspended() ||
- executionContext->IsContextDestroyed())
+ DCHECK(!executionContext->IsContextSuspended());
+ if (!executionContext || executionContext->IsContextDestroyed())
return;
if (!m_scriptState->ContextIsValid())
return;
@@ -200,8 +200,8 @@ void V8TestCallbackInterface::voidMethodTestInterfaceEmptyStringArg(TestInterfac
void V8TestCallbackInterface::callbackWithThisValueVoidMethodStringArg(ScriptValue thisValue, const String& stringArg) {
ExecutionContext* executionContext =
ExecutionContext::From(m_scriptState.Get());
- if (!executionContext || executionContext->IsContextSuspended() ||
- executionContext->IsContextDestroyed())
+ DCHECK(!executionContext->IsContextSuspended());
+ if (!executionContext || executionContext->IsContextDestroyed())
return;
if (!m_scriptState->ContextIsValid())
return;
« no previous file with comments | « third_party/WebKit/Source/bindings/templates/callback_interface.cpp.tmpl ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698