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

Commit 209fcf86 authored by Jack He's avatar Jack He
Browse files

Revert "GATT: Unregister notifications when disconnecting"

This reverts commit 61f45415.

Reason for revert: accidental merge of CL

Bug: 231818024
Test: presubmit
Change-Id: I704b34c4864da4e93920ccdfd49863714d7099d7
parent 61f45415
Loading
Loading
Loading
Loading
+0 −8
Original line number Original line Diff line number Diff line
@@ -588,14 +588,6 @@ void bta_gattc_close(tBTA_GATTC_CLCB* p_clcb, const tBTA_GATTC_DATA* p_data) {
  if (p_clcb->transport == BT_TRANSPORT_BR_EDR)
  if (p_clcb->transport == BT_TRANSPORT_BR_EDR)
    bta_sys_conn_close(BTA_ID_GATTC, BTA_ALL_APP_ID, p_clcb->bda);
    bta_sys_conn_close(BTA_ID_GATTC, BTA_ALL_APP_ID, p_clcb->bda);


  /* Clean up notification registration for closed client */
  for (int i = 0; i < BTA_GATTC_NOTIF_REG_MAX; i++) {
    if (p_clreg->notif_reg[i].in_use &&
        p_clreg->notif_reg[i].remote_bda == p_clcb->bda) {
      p_clreg->notif_reg[i] = {};
    }
  }

  bta_gattc_clcb_dealloc(p_clcb);
  bta_gattc_clcb_dealloc(p_clcb);


  if (p_data->hdr.event == BTA_GATTC_API_CLOSE_EVT) {
  if (p_data->hdr.event == BTA_GATTC_API_CLOSE_EVT) {