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

Commit c21b534a authored by Sharvil Nanavati's avatar Sharvil Nanavati
Browse files

DO NOT MERGE ANYWHERE Don't send BT+BCC if local device doesn't support codec negotiation.

The current code only checked if the peer supported codec negotiation
before sending AT+BCC. But if codec negotation is disabled on the
local device, we should definitely not send AT+BCC.

Bug: 27213013
Change-Id: Id372a32a61a3d96d5c093bc50594ef0b8c2eff2e
parent c46a70e8
Loading
Loading
Loading
Loading
+2 −1
Original line number Original line Diff line number Diff line
@@ -271,7 +271,8 @@ static bt_status_t connect_audio( bt_bdaddr_t *bd_addr )


    if (is_connected(bd_addr))
    if (is_connected(bd_addr))
    {
    {
        if (btif_hf_client_cb.peer_feat & BTA_HF_CLIENT_PEER_CODEC)
        if ((BTIF_HF_CLIENT_FEATURES & BTA_HF_CLIENT_FEAT_CODEC) &&
                (btif_hf_client_cb.peer_feat & BTA_HF_CLIENT_PEER_CODEC))
        {
        {
            BTA_HfClientSendAT(btif_hf_client_cb.handle, BTA_HF_CLIENT_AT_CMD_BCC, 0, 0, NULL);
            BTA_HfClientSendAT(btif_hf_client_cb.handle, BTA_HF_CLIENT_AT_CMD_BCC, 0, 0, NULL);
        }
        }