Skip to content
Commit 86ce1809 authored by Jernej Virag's avatar Jernej Virag
Browse files

Do not keep MediaSession Tokens for Notification accounting

In some cases we're tracking 50+ MediaSession.Tokens being retained. Since Tokens contain strong binder links, they can retain big resources on the other side of the link.

The code inside MediaSessionBasedFilter doesn't actually need to hold tokens at all - it just tests for equality between tokens. As such, we can only retain their identifiers and let Tokens themselves be deallocated if necessary.

Bug: 261882243
Test: atest MediaSessionBasedFilterTest, verified Media behaviour on device
Change-Id: I65fc3b47ad87cd6b90a814ef217b2ec1c90cac29
parent de157676
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