Commit 23ece3f8 authored by erikchen's avatar erikchen Committed by Commit bot

Add a useful DCHECK to RestoreCurrentTextureBindings.

BUG=624080
CQ_INCLUDE_TRYBOTS=tryserver.chromium.linux:linux_optional_gpu_tests_rel;tryserver.chromium.mac:mac_optional_gpu_tests_rel;tryserver.chromium.win:win_optional_gpu_tests_rel

Review-Url: https://codereview.chromium.org/2104943003
Cr-Commit-Position: refs/heads/master@{#403929}
parent b1320e8f
...@@ -2298,6 +2298,7 @@ ScopedGLErrorSuppressor::~ScopedGLErrorSuppressor() { ...@@ -2298,6 +2298,7 @@ ScopedGLErrorSuppressor::~ScopedGLErrorSuppressor() {
} }
static void RestoreCurrentTextureBindings(ContextState* state, GLenum target) { static void RestoreCurrentTextureBindings(ContextState* state, GLenum target) {
DCHECK(!state->texture_units.empty());
TextureUnit& info = state->texture_units[0]; TextureUnit& info = state->texture_units[0];
GLuint last_id; GLuint last_id;
scoped_refptr<TextureRef>& texture_ref = info.GetInfoForTarget(target); scoped_refptr<TextureRef>& texture_ref = info.GetInfoForTarget(target);
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment