Fix valgrind issue in CircleBatch__Test

TBR=bsalomon@google.com
GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=2271653002

Review-Url: https://codereview.chromium.org/2271653002
This commit is contained in:
robertphillips 2016-08-23 06:19:15 -07:00 committed by Commit bot
parent d01c7d09e9
commit 08197b2265

View File

@ -1935,7 +1935,8 @@ DRAW_BATCH_TEST_DEFINE(CircleBatch) {
const CircleBatch::ArcParams* arcParams = nullptr; const CircleBatch::ArcParams* arcParams = nullptr;
if (random->nextBool()) { if (random->nextBool()) {
arcParamsTmp.fStartAngleRadians = random->nextSScalar1() * SK_ScalarPI * 2; arcParamsTmp.fStartAngleRadians = random->nextSScalar1() * SK_ScalarPI * 2;
arcParamsTmp.fStartAngleRadians = random->nextSScalar1() * SK_ScalarPI * 2 - .01f; arcParamsTmp.fSweepAngleRadians = random->nextSScalar1() * SK_ScalarPI * 2 - .01f;
arcParamsTmp.fUseCenter = random->nextBool();
arcParams = &arcParamsTmp; arcParams = &arcParamsTmp;
} }
GrDrawBatch* batch = CircleBatch::Create(color, viewMatrix, center, radius, GrDrawBatch* batch = CircleBatch::Create(color, viewMatrix, center, radius,