Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 7f4d4fc8 authored by Dan Austin's avatar Dan Austin Committed by Gerrit Code Review
Browse files

Merge "Fix benign overflow in ToneGenerator.cpp"

parents 9f66254d 6f5a43f4
Loading
Loading
Loading
Loading
+4 −2
Original line number Diff line number Diff line
@@ -1581,7 +1581,8 @@ void ToneGenerator::WaveGenerator::getSamples(short *outBuffer,
        }
        long dec = lAmplitude/count;
        // loop generation
        while (count--) {
        while (count) {
            count--;
            Sample = ((lA1 * lS1) >> S_Q14) - lS2;
            // shift delay
            lS2 = lS1;
@@ -1592,7 +1593,8 @@ void ToneGenerator::WaveGenerator::getSamples(short *outBuffer,
        }
    } else {
        // loop generation
        while (count--) {
        while (count) {
            count--;
            Sample = ((lA1 * lS1) >> S_Q14) - lS2;
            // shift delay
            lS2 = lS1;