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

Commit e94c27a1 authored by Mikhail Naganov's avatar Mikhail Naganov
Browse files

audioflinger: Fix battery accounting for offload tracks

Ensure that the list of wakelock UIDs is only cleared if
the offload playback wakelock is released during async completion
wait.

Bug: 30830106
Change-Id: Icf18b9e88e55c27bc03d8a904cc91f593cc95815
parent 15223ec2
Loading
Loading
Loading
Loading
+2 −2
Original line number Diff line number Diff line
@@ -3106,9 +3106,9 @@ bool AudioFlinger::PlaybackThread::threadLoop()
                if (!keepWakeLock()) {
                    releaseWakeLock_l();
                    released = true;
                }
                    mWakeLockUids.clear();
                    mActiveTracksGeneration++;
                }
                ALOGV("wait async completion");
                mWaitWorkCV.wait(mLock);
                ALOGV("async completion/wake");