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

Unified Diff: ui/gl/gl_context.cc

Issue 2852353003: Add more strict DCHECKs around context state. (Closed)
Patch Set: 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
Index: ui/gl/gl_context.cc
diff --git a/ui/gl/gl_context.cc b/ui/gl/gl_context.cc
index 08a0c78b6e4825ed86b7c0f66f0c8ad6cb83d1b3..121b624e9bf2bf84d62d9d5a20fa663d5a665594 100644
--- a/ui/gl/gl_context.cc
+++ b/ui/gl/gl_context.cc
@@ -266,7 +266,6 @@ bool GLContext::MakeVirtuallyCurrent(
DCHECK_EQ(this, GLContext::GetRealCurrent());
DCHECK(IsCurrent(NULL));
- DCHECK(virtual_context->IsCurrent(surface));
if (switched_real_contexts || virtual_context != current_virtual_context_) {
#if DCHECK_IS_ON()
@@ -301,6 +300,7 @@ bool GLContext::MakeVirtuallyCurrent(
LOG(ERROR) << "Could not make GLSurface current.";
return false;
}
+ DCHECK(virtual_context->IsCurrent(surface));
return true;
}

Powered by Google App Engine
This is Rietveld 408576698