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

Commit 6e3d2ce0 authored by Jakub Tyszkowski's avatar Jakub Tyszkowski
Browse files

LeAudio: Fix autoconnect flag storage

The main device was used instead of the other member.

Bug: 285076926
Test: atest bluetooth_le_audio_client_test
Change-Id: I7e16c26fa58a1b8204724a59299a313f5d5d8b5f
parent 45762a9b
Loading
Loading
Loading
Loading
+2 −2
Original line number Diff line number Diff line
@@ -1494,9 +1494,9 @@ class LeAudioClientImpl : public LeAudioClient {
               dev = group->GetNextDevice(dev)) {
            if (dev->GetConnectionState() ==
                DeviceConnectState::CONNECTING_AUTOCONNECT) {
              btif_storage_set_leaudio_autoconnect(address, false);
              btif_storage_set_leaudio_autoconnect(dev->address_, false);
              dev->autoconnect_flag_ = false;
              BTA_GATTC_CancelOpen(gatt_if_, address, false);
              BTA_GATTC_CancelOpen(gatt_if_, dev->address_, false);
              dev->SetConnectionState(DeviceConnectState::DISCONNECTED);
            }
          }