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

Commit 2898a7df authored by TreeHugger Robot's avatar TreeHugger Robot Committed by Android (Google) Code Review
Browse files

Merge "LeAudioService: Clear lead device when removed from the group" into tm-qpr-dev

parents 51ac59bb 02b70e85
Loading
Loading
Loading
Loading
+5 −0
Original line number Diff line number Diff line
@@ -1845,6 +1845,11 @@ public class LeAudioService extends ProfileService {
    }

    private void handleGroupNodeRemoved(BluetoothDevice device, int groupId) {
        LeAudioGroupDescriptor descriptor = getGroupDescriptor(groupId);
        if (Objects.equals(device, descriptor.mLostLeadDeviceWhileStreaming)) {
            clearLostDevicesWhileStreaming(descriptor);
        }

        synchronized (mGroupLock) {
            mDeviceGroupIdMap.remove(device);
            if (!mDeviceGroupIdMap.containsValue(groupId)) {