From 8b61fc9b6f7785a4440d2b57d5be726db13bd703 Mon Sep 17 00:00:00 2001 From: ShadowNinja Date: Mon, 4 May 2015 19:59:36 -0400 Subject: [PATCH] Fix GCC compiler warning --- src/unittest/test_random.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/unittest/test_random.cpp b/src/unittest/test_random.cpp index 81cf9ae2..20cfca33 100644 --- a/src/unittest/test_random.cpp +++ b/src/unittest/test_random.cpp @@ -173,8 +173,8 @@ void TestRandom::testPcgRandomNormalDist() UASSERT(ubound <= max); int accum = 0; - for (int i = lbound; i != ubound; i++) - accum += bins[i - min]; + for (int j = lbound; j != ubound; j++) + accum += bins[j - min]; float actual = (float)accum / num_samples; UASSERT(fabs(actual - prediction_intervals[i]) < 0.02);