aboutsummaryrefslogtreecommitdiffhomepage
path: root/tests/BitmapCopyTest.cpp
diff options
context:
space:
mode:
authorGravatar Brian Salomon <bsalomon@google.com>2016-01-11 15:15:46 -0500
committerGravatar Brian Salomon <bsalomon@google.com>2016-01-11 15:15:46 -0500
commit639475e375b7e62277ac5e5b96eadeaaa1afcddc (patch)
treedb0ffb2520583b93297228acb8ee1bb43cc2594d /tests/BitmapCopyTest.cpp
parent950e626fb43004c010aa4d9d5ff5247e0d5f94fa (diff)
Fix BitmapCopy_Texture test on iOS
Diffstat (limited to 'tests/BitmapCopyTest.cpp')
-rw-r--r--tests/BitmapCopyTest.cpp4
1 files changed, 4 insertions, 0 deletions
diff --git a/tests/BitmapCopyTest.cpp b/tests/BitmapCopyTest.cpp
index 8b2cb3ce54..70998bd3f0 100644
--- a/tests/BitmapCopyTest.cpp
+++ b/tests/BitmapCopyTest.cpp
@@ -669,6 +669,10 @@ DEF_GPUTEST_FOR_RENDERING_CONTEXTS(BitmapCopy_Texture, reporter, ctx) {
SkAutoTUnref<GrTexture> texture(
ctx->textureProvider()->createTexture(desc, false, srcData, 0));
+ if (!texture) {
+ continue;
+ }
+
SkBitmap srcBmp;
GrWrapTextureInBitmap(texture, 2, 2, false, &srcBmp);
if (srcBmp.isNull()) {