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

Commit f8c88d0b authored by Archie Pusaka's avatar Archie Pusaka Committed by Gerrit Code Review
Browse files

Merge "Don't invoke search complete when cancelling remote name request" into main

parents 17c582b4 d9f220a7
Loading
Loading
Loading
Loading
+8 −2
Original line number Diff line number Diff line
@@ -26,7 +26,7 @@
#include <cstdint>
#include <vector>

#include "bta/dm/bta_dm_disc.h"
#include "android_bluetooth_flags.h"
#include "bta/dm/bta_dm_disc_int.h"
#include "bta/include/bta_gatt_api.h"
#include "bta/include/bta_sdp_api.h"
@@ -310,7 +310,13 @@ static void bta_dm_search_cancel() {
     active */
  else if (!bta_dm_search_cb.name_discover_done) {
    get_btm_client_interface().peer.BTM_CancelRemoteDeviceName();
#ifndef TARGET_FLOSS
    /* bta_dm_search_cmpl is called when receiving the remote name cancel evt */
    if (!IS_FLAG_ENABLED(
            bta_dm_defer_device_discovery_state_change_until_rnr_complete)) {
      bta_dm_search_cmpl();
    }
#endif
  } else {
    bta_dm_inq_cmpl(0);
  }