Discard ops that don't have a finite bounds.
Bug: chromium:905782
Change-Id: I2f83d0371dad5d812163cd15af4690983a6e074f
Reviewed-on: https://skia-review.googlesource.com/c/171533
Reviewed-by: Brian Osman <brianosman@google.com>
Commit-Queue: Brian Salomon <bsalomon@google.com>
diff --git a/src/gpu/GrRenderTargetOpList.cpp b/src/gpu/GrRenderTargetOpList.cpp
index 30b5f5c..010fe6c 100644
--- a/src/gpu/GrRenderTargetOpList.cpp
+++ b/src/gpu/GrRenderTargetOpList.cpp
@@ -619,6 +619,10 @@
// A closed GrOpList should never receive new/more ops
SkASSERT(!this->isClosed());
+ if (!op->bounds().isFinite()) {
+ fOpMemoryPool->release(std::move(op));
+ return;
+ }
// Check if there is an op we can combine with by linearly searching back until we either
// 1) check every op