We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent c6025ca commit 33a6323Copy full SHA for 33a6323
src/ScaleStabilizer.cpp
@@ -90,7 +90,10 @@ void ScaleStabilizer::add(double reading)
90
int oldestReadingIdx = (_currentReadingIdx + 1) % _windowSize;
91
_window[oldestReadingIdx] = reading;
92
_currentReadingIdx = oldestReadingIdx;
93
- _abortCounter = _abortCounter < _windowSize / 2 ? _abortCounter++ : _abortCounter;
+ if (_abortCounter < _windowSize / 2)
94
+ {
95
+ _abortCounter++;
96
+ }
97
return;
98
}
99
0 commit comments