aboutsummaryrefslogtreecommitdiffhomepage
path: root/tests/EGLImageTest.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'tests/EGLImageTest.cpp')
-rw-r--r--tests/EGLImageTest.cpp3
1 files changed, 2 insertions, 1 deletions
diff --git a/tests/EGLImageTest.cpp b/tests/EGLImageTest.cpp
index 9ea6379dc6..efa7de20d7 100644
--- a/tests/EGLImageTest.cpp
+++ b/tests/EGLImageTest.cpp
@@ -88,7 +88,8 @@ DEF_GPUTEST_FOR_GL_RENDERING_CONTEXTS(EGLImageTest, reporter, ctxInfo) {
backendTexture1 =
gpu1->createTestingOnlyBackendTexture(nullptr, kSize, kSize, kRGBA_8888_GrPixelConfig,
false, GrMipMapped::kNo);
- if (!gpu1->isTestingOnlyBackendTexture(backendTexture1)) {
+
+ if (!backendTexture1.isValid() || !gpu1->isTestingOnlyBackendTexture(backendTexture1)) {
ERRORF(reporter, "Error creating texture for EGL Image");
cleanup(glCtx0, externalTexture.fID, glCtx1.get(), context1, &backendTexture1, image);
return;