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

Commit bb71204b authored by Treehugger Robot's avatar Treehugger Robot Committed by Automerger Merge Worker
Browse files

Merge "Check if stack down before caching scan result" am: 0ad31ce7 am: f2217deb am: 0eb2def8

Original change: https://android-review.googlesource.com/c/platform/packages/modules/Bluetooth/+/1984786

Change-Id: Id2bf4fb5b4e215ccb99ea6d9f88bc9b7b7df7c8f
parents 5faca187 0eb2def8
Loading
Loading
Loading
Loading
+5 −5
Original line number Diff line number Diff line
@@ -494,6 +494,11 @@ bool BleScannerInterfaceImpl::parse_filter_command(
void BleScannerInterfaceImpl::handle_remote_properties(
    RawAddress bd_addr, tBLE_ADDR_TYPE addr_type,
    std::vector<uint8_t> advertising_data) {
  if (!bluetooth::shim::is_gd_stack_started_up()) {
    LOG_WARN("Gd stack is stopped, return");
    return;
  }

  // skip anonymous advertisment
  if (addr_type == BLE_ADDR_ANONYMOUS) {
    return;
@@ -541,11 +546,6 @@ void BleScannerInterfaceImpl::handle_remote_properties(
      }
    }
  }
  if (!bluetooth::shim::is_gd_stack_started_up()) {
    LOG_WARN("Gd stack is stopped, return");
    return;
  }

  auto* storage_module = bluetooth::shim::GetStorage();
  bluetooth::hci::Address address = ToGdAddress(bd_addr);