Index: src/gpu/GrDrawContext.cpp |
diff --git a/src/gpu/GrDrawContext.cpp b/src/gpu/GrDrawContext.cpp |
index af04f74fcfd13c5a1aa0cb9b3d9872078ff9ef05..6c80f52bba5c9260e815fed142a708bd1e0708d1 100644 |
--- a/src/gpu/GrDrawContext.cpp |
+++ b/src/gpu/GrDrawContext.cpp |
@@ -822,9 +822,10 @@ void GrDrawContext::drawPath(const GrClip& clip, |
if (is_nested_rects(viewMatrix, path, strokeInfo, rects)) { |
SkAutoTUnref<GrDrawBatch> batch(GrRectBatchFactory::CreateAAFillNestedRects( |
paint.getColor(), viewMatrix, rects)); |
- |
- GrPipelineBuilder pipelineBuilder(paint, fRenderTarget.get(), clip); |
- this->getDrawTarget()->drawBatch(pipelineBuilder, batch); |
+ if (batch) { |
+ GrPipelineBuilder pipelineBuilder(paint, fRenderTarget.get(), clip); |
+ this->getDrawTarget()->drawBatch(pipelineBuilder, batch); |
+ } |
return; |
} |
} |