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

Commit 76a5c170 authored by Chris Manton's avatar Chris Manton
Browse files

[18/19] get_btm_client_interface().sco.BTM_IsScoActiveByBdaddr

Bug: 343772702
Test: m .
Flag: EXEMPT, Mechanical Refactor

Change-Id: I7d0be7773beabceba95540ad233146352455906e
parent b6d78c8c
Loading
Loading
Loading
Loading
+2 −3
Original line number Diff line number Diff line
@@ -50,7 +50,6 @@
#include "main/shim/dumpsys.h"
#include "main/shim/entry.h"
#include "main/shim/helpers.h"
#include "os/log.h"
#include "os/parameter_provider.h"
#include "osi/include/allocator.h"
#include "osi/include/properties.h"
@@ -69,8 +68,8 @@
#include "stack/include/acl_hci_link_interface.h"
#include "stack/include/bt_hdr.h"
#include "stack/include/bt_types.h"
#include "stack/include/btm_api.h"
#include "stack/include/btm_ble_api.h"
#include "stack/include/btm_client_interface.h"
#include "stack/include/btm_iso_api.h"
#include "stack/include/hci_error_code.h"
#include "stack/include/hcimsgs.h"
@@ -578,7 +577,7 @@ tBTM_STATUS BTM_SwitchRoleToCentral(const RawAddress& remote_bd_addr) {
    return BTM_DEV_RESTRICT_LISTED;
  }

  if (BTM_IsScoActiveByBdaddr(remote_bd_addr)) {
  if (get_btm_client_interface().sco.BTM_IsScoActiveByBdaddr(remote_bd_addr)) {
    log::info("An active SCO to device prevents role switch at this time");
    return BTM_NO_RESOURCES;
  }