Misc. clang static analyzer fixes

This commit is contained in:
Émilie Feral
2020-12-08 10:45:49 +01:00
committed by LeaNumworks
parent c3ceb0074f
commit fe4e2e3e9d
5 changed files with 5 additions and 1 deletions

View File

@@ -294,7 +294,7 @@ void Zoom::RangeWithRatioForDisplay(ValueAtAbscissa evaluation, float yxRatio, f
* dealing with linear functions. */
float yRange = yxRatio * xRange;
int j = 1;
int bestIndex, bestBreadth = 0, bestDistanceToCenter;
int bestIndex = 0, bestBreadth = 0, bestDistanceToCenter;
for (int i = 0; i < sampleSize; i++) {
if (sampleSize - i < bestBreadth) {
break;