Index: src/gpu/effects/GrConvexPolyEffect.cpp |
diff --git a/src/gpu/effects/GrConvexPolyEffect.cpp b/src/gpu/effects/GrConvexPolyEffect.cpp |
index 4616bdb7a3a6e18aa7097b273681ae3a6d825086..e47ed0f86606b93d42913c8ad298023fefa4e276 100644 |
--- a/src/gpu/effects/GrConvexPolyEffect.cpp |
+++ b/src/gpu/effects/GrConvexPolyEffect.cpp |
@@ -174,7 +174,7 @@ GrEffectRef* GrConvexPolyEffect::TestCreate(SkRandom* random, |
const GrDrawTargetCaps& caps, |
GrTexture*[]) { |
EdgeType edgeType = static_cast<EdgeType>(random->nextULessThan(kEdgeTypeCnt)); |
- int count = random->nextULessThan(kMaxEdges + 1); |
+ int count = random->nextULessThan(kMaxEdges) + 1; |
SkScalar edges[kMaxEdges * 3]; |
for (int i = 0; i < 3 * count; ++i) { |
edges[i] = random->nextSScalar1(); |