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

Commit 9977b476 authored by Dan Austin's avatar Dan Austin Committed by Android Git Automerger
Browse files

am b7132738: am 7f4d4fc8: Merge "Fix benign overflow in ToneGenerator.cpp"

* commit 'b7132738':
  Fix benign overflow in ToneGenerator.cpp
parents 66cd93d4 b7132738
Loading
Loading
Loading
Loading
+4 −2
Original line number Diff line number Diff line
@@ -1580,7 +1580,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;
@@ -1591,7 +1592,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;