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

Skip to content
Commit 37a6163f authored by Steven Moreland's avatar Steven Moreland
Browse files

oboeservice: hold onto linked binder

Before, in Android 10, this would have been a small leak because
unlinkToDeath is not called, but now, objects are automatically
unlinked. However, this presents a problem since you must hold onto
a binder in order to linkToDeath. This now holds onto the binder
and is relying on the automatic-unlinkToDeath behavior.

Fixes: 145675653
Test: atest CtsNativeMediaAAudioTestCases
arm64-v8a CtsNativeMediaAAudioTestCases: Passed: 122, Failed: 0, Ignored: 0, Assumption Failed: 0
Test: after using app and killing which uses AAudio MMAP stream,
dumpsys output for media.aaudio is cleaned up:

------------ AAudio Service ------------
Stream Handles:
AAudioClientTracker:
AAudioEndpointManager:
Exclusive MMAP Endpoints: 0
 ExclusiveSearchCount:  3
 ExclusiveFoundCount:   0
 ExclusiveOpenCount:    1
 ExclusiveCloseCount:   1

Shared Endpoints: 0
 SharedSearchCount:     1
 SharedFoundCount:      0
 SharedOpenCount:       0
 SharedCloseCount:      0

Change-Id: I2ef141320dc3ef0135fb7ef002d85377d06a75c2
parent b2872d47
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