[BUG] AudioService: PlaybackActivityMonitor: fix exploding list

This CL fixes the growing list of Playback Monitor client by
comparing the cb.asBinder() object to correctly find
the previous registration.

Test: todo

Signed-off-by: Francois Gaffie <francois.gaffie@renault.com>
Change-Id: Ib4ad166f584fe60c2a1e5721f3ab51e9a4151d41
This commit is contained in:
Francois Gaffie
2021-07-02 15:27:41 +02:00
parent fdd15ef637
commit 3c518a3bd6

View File

@@ -779,7 +779,7 @@ public final class PlaybackActivityMonitor
// the same time if we still have a public client.
while (clientIterator.hasNext()) {
PlayMonitorClient pmc = clientIterator.next();
if (pcdb.equals(pmc.mDispatcherCb)) {
if (pcdb.asBinder().equals(pmc.mDispatcherCb.asBinder())) {
pmc.release();
clientIterator.remove();
} else {