diff options
author | 2013-11-12 17:33:02 +0000 | |
---|---|---|
committer | 2013-11-12 17:33:02 +0000 | |
commit | 5fa42d1621c74d206fe746ec2c5b7962a97cf6d1 (patch) | |
tree | cf85acb3a57b46bd05a629e3edcdcadffab0c76b /tests | |
parent | cac8d01eabd05d11365f56b6af3f30bccb173487 (diff) |
"Fix" another crash on valgrind bot
https://codereview.chromium.org/70463002/
git-svn-id: http://skia.googlecode.com/svn/trunk@12248 2bbb7eff-a529-9590-31e7-b0007b416f81
Diffstat (limited to 'tests')
-rw-r--r-- | tests/DeferredCanvasTest.cpp | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/tests/DeferredCanvasTest.cpp b/tests/DeferredCanvasTest.cpp index a9679a339d..bcee382250 100644 --- a/tests/DeferredCanvasTest.cpp +++ b/tests/DeferredCanvasTest.cpp @@ -703,6 +703,10 @@ static void TestDeferredCanvasSurface(skiatest::Reporter* reporter, GrContextFac #if SK_SUPPORT_GPU if (useGpu) { GrContext* context = factory->get(GrContextFactory::kNative_GLContextType); + if (NULL == context) { + return; + } + surface = SkSurface::NewRenderTarget(context, imageSpec); } else { surface = SkSurface::NewRaster(imageSpec); |