ref: 6c1aa2943196eab4c4b11815d69ac978484bad64
parent: dc067286b3bfd3c2f3178a51d54c0a5f495cc56a
author: Martin Storsjö <martin@martin.st>
date: Wed Feb 4 06:25:09 EST 2015
Avoid declaring a new variable shadowing an existing one in the same function All the following loops below assume that int iIdx already is declared.
--- a/test/api/encode_decode_api_test.cpp
+++ b/test/api/encode_decode_api_test.cpp
@@ -3175,7 +3175,7 @@
int iIdx = 0;
//create decoder
- for (int iIdx = 0; iIdx < iSpatialLayerNum; iIdx++) {
+ for (iIdx = 0; iIdx < iSpatialLayerNum; iIdx++) {
pBsBuf[iIdx] = static_cast<unsigned char*> (malloc (iWidth * iHeight * 3 * sizeof (unsigned char) / 2));
aLen[iIdx] = 0;