commit | c0682eaa0a85f722858be4767f5452afc26efb04 | [log] [tgz] |
---|---|---|
author | Vlad Popa <pvlad@google.com> | Tue Jan 23 16:09:49 2024 -0800 |
committer | Vlad Popa <pvlad@google.com> | Tue Jan 23 16:12:40 2024 -0800 |
tree | 97202d1e8bab63fdb9f42925b83ec31ca6036f74 | |
parent | c121002af86ffb7a24489268da05b35dd647d1df [diff] |
CTA2075: Fix possible race condition When accessing the MediaCodecs from the audio service callback the client can still change the codecs which are tracked for receiving updates. Hence, lock the parameterupdate when iterating over the loudness controller codecs. Test: atest "CtsMediaAudioTestCases:android.media.audio.cts.LoudnessCodecControllerTest#multipleLcc_withRegisteredCodecs_triggerUpdate" --iterations 100 Bug: 321868864 Change-Id: I7aedc85d9d143497d089ae7f613f9fb5897f916d