OSDN Git Service

Use proper bta/gatt/bta_gattc_act::gatt_disconnection_reason_text
authorChris Manton <cmanton@google.com>
Wed, 13 Jan 2021 01:33:30 +0000 (17:33 -0800)
committerChris Manton <cmanton@google.com>
Wed, 13 Jan 2021 07:15:11 +0000 (23:15 -0800)
Towards loggable code

Bug: 163134718
Tag: #refactor
Test: gd/cert/run

Change-Id: I81cdee3a3ececda20bbc882c8892be945c72cb94

bta/gatt/bta_gattc_act.cc

index 390fbd0..18cb696 100644 (file)
@@ -1068,12 +1068,12 @@ static void bta_gattc_conn_cback(tGATT_IF gattc_if, const RawAddress& bdaddr,
   if (connected) {
     LOG_INFO("Connected att_id:%hhu transport:%s reason:%s", gattc_if,
              BtTransportText(transport).c_str(),
-             hci_error_code_text(reason).c_str());
+             gatt_disconnection_reason_text(reason).c_str());
     btif_debug_conn_state(bdaddr, BTIF_DEBUG_CONNECTED, GATT_CONN_UNKNOWN);
   } else {
     LOG_INFO("Disconnected att_id:%hhu transport:%s reason:%s", gattc_if,
              BtTransportText(transport).c_str(),
-             hci_error_code_text(reason).c_str());
+             gatt_disconnection_reason_text(reason).c_str());
     btif_debug_conn_state(bdaddr, BTIF_DEBUG_DISCONNECTED, GATT_CONN_UNKNOWN);
   }