Stop overflow of windows rects in GrClipStack
Bug: skia:10989
Change-Id: I512ccbd3d95178756ae436f7c67ed53d46105ae7
Reviewed-on: https://skia-review.googlesource.com/c/skia/+/339165
Reviewed-by: Michael Ludwig <michaelludwig@google.com>
Reviewed-by: Brian Salomon <bsalomon@google.com>
Commit-Queue: Robert Phillips <robertphillips@google.com>
diff --git a/src/gpu/GrWindowRectangles.h b/src/gpu/GrWindowRectangles.h
index 40f7582..6658162 100644
--- a/src/gpu/GrWindowRectangles.h
+++ b/src/gpu/GrWindowRectangles.h
@@ -48,7 +48,7 @@
struct GrWindowRectangles::Rec : public GrNonAtomicRef<Rec> {
Rec(const SkIRect* windows, int numWindows) {
- SkASSERT(numWindows < kMaxWindows);
+ SkASSERT(numWindows <= kMaxWindows);
memcpy(fData, windows, sizeof(SkIRect) * numWindows);
}
Rec() = default;