Fix the format specifiers in CHPP am: 8e32509516
Original change: undetermined
Change-Id: Iac132d280418a0a0feec00ace9d23aff79dbf914
diff --git a/chpp/clients/discovery.c b/chpp/clients/discovery.c
index e965e84..e274551 100644
--- a/chpp/clients/discovery.c
+++ b/chpp/clients/discovery.c
@@ -115,7 +115,7 @@
if (serviceCount >= CHPP_MAX_DISCOVERED_SERVICES) {
CHPP_LOGE("Discovered service count = %" PRIu8
- " larger than CHPP_MAX_DISCOVERED_SERVICES = %" PRIu8,
+ " larger than CHPP_MAX_DISCOVERED_SERVICES = %d",
serviceCount, CHPP_MAX_DISCOVERED_SERVICES);
CHPP_DEBUG_ASSERT(false);
}
@@ -135,17 +135,18 @@
chppUuidToStr(response->services[i].uuid, uuidText);
if (context->clientIndexOfServiceIndex[i] == CHPP_CLIENT_INDEX_NONE) {
- CHPP_LOGI("No matching client found for service on handle %" PRIu8
- " with name=%s, UUID=%s, version=%" PRIu8 ".%" PRIu8
- ".%" PRIu16,
- CHPP_SERVICE_HANDLE_OF_INDEX(i), response->services[i].name,
- uuidText, response->services[i].version.major,
- response->services[i].version.minor,
- response->services[i].version.patch);
+ CHPP_LOGI(
+ "No matching client found for service on handle %d"
+ " with name=%s, UUID=%s, version=%" PRIu8 ".%" PRIu8 ".%" PRIu16,
+ CHPP_SERVICE_HANDLE_OF_INDEX(i), response->services[i].name, uuidText,
+ response->services[i].version.major,
+ response->services[i].version.minor,
+ response->services[i].version.patch);
} else {
CHPP_LOGI(
- "Client # %" PRIu8 " matched to service on handle %" PRIu8
+ "Client # %" PRIu8
+ " matched to service on handle %d"
" with name=%s, UUID=%s. "
"client version=%" PRIu8 ".%" PRIu8 ".%" PRIu16
", service version=%" PRIu8 ".%" PRIu8 ".%" PRIu16,
diff --git a/chpp/services.c b/chpp/services.c
index 0f6640f..bd64f00 100644
--- a/chpp/services.c
+++ b/chpp/services.c
@@ -98,7 +98,8 @@
char uuidText[CHPP_SERVICE_UUID_STRING_LEN];
chppUuidToStr(newService->descriptor.uuid, uuidText);
- CHPP_LOGI("Registered service # %" PRIu8 " on handle %" PRIu8
+ CHPP_LOGI("Registered service # %" PRIu8
+ " on handle %d"
" with name=%s, UUID=%s, version=%" PRIu8 ".%" PRIu8 ".%" PRIu16
", min_len=%" PRIuSIZE " ",
appContext->registeredServiceCount,
diff --git a/chpp/transport.c b/chpp/transport.c
index dacea6b..5a5ffc0 100644
--- a/chpp/transport.c
+++ b/chpp/transport.c
@@ -307,7 +307,7 @@
context->rxHeader.seq, context->rxHeader.length);
} else {
- CHPP_LOGD("RX good packet. payload len=%" PRIu8 ", seq=%" PRIu8
+ CHPP_LOGD("RX good packet. payload len=%" PRIu16 ", seq=%" PRIu8
", ackSeq=%" PRIu8 ", flags=0x%" PRIx8 ", packetCode=0x%" PRIx8,
context->rxHeader.length, context->rxHeader.seq,
context->rxHeader.ackSeq, context->rxHeader.flags,
@@ -484,7 +484,7 @@
result = CHPP_TRANSPORT_ERROR_ORDER;
CHPP_LOGE("Invalid RX packet header. Unexpected seq=%" PRIu8
- " (expected=%" PRIu8 "), len=%" PRIu8,
+ " (expected=%" PRIu8 "), len=%" PRIu16,
context->rxHeader.seq, context->rxStatus.expectedSeq,
context->rxHeader.length);
}
@@ -620,7 +620,7 @@
} else {
CHPP_LOGD("Dequeuing front datagram with index=%" PRIu8 ", len=%" PRIuSIZE
- ". Queue depth: %" PRIu8 "->%" PRIu8,
+ ". Queue depth: %" PRIu8 "->%d",
context->txDatagramQueue.front,
context->txDatagramQueue.datagram[context->txDatagramQueue.front]
.length,
@@ -834,7 +834,7 @@
if (len < sizeof(struct ChppAppHeader)) {
CHPP_LOGD("Enqueueing TX datagram (packet code=0x%" PRIx8
", len=%" PRIuSIZE ") for handle=%" PRIu8
- ". Queue depth: %" PRIu8 "->%" PRIu8,
+ ". Queue depth: %" PRIu8 "->%d",
packetCode, len, *handle, context->txDatagramQueue.pending,
context->txDatagramQueue.pending + 1);
} else {
@@ -842,7 +842,7 @@
CHPP_LOGD("Enqueueing TX datagram (packet code=0x%" PRIx8
", len=%" PRIuSIZE ") for handle=%" PRIu8 ", type=0x%" PRIx8
", transaction ID=%" PRIu8 ", error=%" PRIu8
- ", command=0x%" PRIx16 ". Queue depth: %" PRIu8 "->%" PRIu8,
+ ", command=0x%" PRIx16 ". Queue depth: %" PRIu8 "->%d",
packetCode, len, header->handle, header->type,
header->transaction, header->error, header->command,
context->txDatagramQueue.pending,