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

Skip to content
Commit 92d0a325 authored by Eric Laurent's avatar Eric Laurent
Browse files

audio flinger: shared audio record fixes

Fix several issues with shared audio record history implementation:
- Resetting the shared audio package name when detroyinng a RecordTrack
did not work because RecordThread::shareAudioHistory_l() bailed if the
session ID was not specified: create a new method to reset the shared
audio package and session explicitly.
- RecordThread::getOldestFront_l() must not return a value lagging more
than mRsmpInFrames behind mRsmpInRear because the caller does not check
this condition and can reach outside of the buffer when
copying data to newly allocated buffer.
- Align RecordThread::shareAudioHistory_l() implementation with the API
documentation that indicates best effort in providing history up to the
specified start time: do not reject the request if the specified start
time does not fit within the allocated buffer duratione but adjust the
start time accordingly.

Test: atest AudioRecordSharedAudioTest
Bug: 192718483
Change-Id: Ib058d2180d16d380bbcb7c61fc7455b663bf1e6a
parent da21f77c
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment