OSDN Git Service

btif_sock_rfc: Use %u for uint32_t
authorYi Kong <yikong@google.com>
Wed, 6 Dec 2017 00:25:56 +0000 (16:25 -0800)
committerMyles Watson <mylesgw@google.com>
Thu, 14 Dec 2017 17:33:30 +0000 (09:33 -0800)
Discovered by the upcoming compiler update.

Test: build
Change-Id: If1497232b8f74bfc95194126a398e62f6eda7672

btif/src/btif_sock_rfc.cc

index b834a6d..4b490a0 100644 (file)
@@ -159,7 +159,7 @@ static rfc_slot_t* find_rfc_slot_by_id(uint32_t id) {
   for (size_t i = 0; i < ARRAY_SIZE(rfc_slots); ++i)
     if (rfc_slots[i].id == id) return &rfc_slots[i];
 
-  LOG_ERROR(LOG_TAG, "%s unable to find RFCOMM slot id: %d", __func__, id);
+  LOG_ERROR(LOG_TAG, "%s unable to find RFCOMM slot id: %u", __func__, id);
   return NULL;
 }
 
@@ -620,7 +620,7 @@ static uint32_t rfcomm_cback(tBTA_JV_EVT event, tBTA_JV* p_data,
       break;
 
     default:
-      LOG_ERROR(LOG_TAG, "%s unhandled event %d, slot id: %zi", __func__, event,
+      LOG_ERROR(LOG_TAG, "%s unhandled event %d, slot id: %u", __func__, event,
                 rfcomm_slot_id);
       break;
   }