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

Commit 1e27c22a authored by Eric Laurent's avatar Eric Laurent
Browse files

Fix unreleased mutex in ToneGenerator stopTone()

Commit 09108ade introduced a regression by not releasing
the ToneGenerator mutex before exiting in case of error.

Bug: 8852855
Change-Id: I8ba2755b218842e2034ed8dbd54b18bf2a5fc571
parent e743d2ec
Loading
Loading
Loading
Loading
+1 −0
Original line number Diff line number Diff line
@@ -1012,6 +1012,7 @@ void ToneGenerator::stopTone() {
        if (lStatus == NO_ERROR) {
            // If the tone was restarted exit now before calling clearWaveGens();
            if (mState != TONE_INIT) {
                mLock.unlock();
                return;
            }
            ALOGV("track stop complete, time %d", (unsigned int)(systemTime()/1000000));