Fix clang warnings in core/jni.
There are a few bugs in here too (mostly people expecting + to
concatenate C strings) :(
Change-Id: I0a243c05c4ea8b56e84896f37814d0fbea4c39d5
diff --git a/core/jni/android_hardware_camera2_CameraMetadata.cpp b/core/jni/android_hardware_camera2_CameraMetadata.cpp
index a6a03e5..9132690 100644
--- a/core/jni/android_hardware_camera2_CameraMetadata.cpp
+++ b/core/jni/android_hardware_camera2_CameraMetadata.cpp
@@ -111,8 +111,8 @@
size_t typeSize = getTypeSize(type);
if (dataBytes % typeSize != 0) {
- ALOGE("%s: Expected dataBytes (%ud) to be divisible by typeSize "
- "(%ud)", __FUNCTION__, dataBytes, typeSize);
+ ALOGE("%s: Expected dataBytes (%zu) to be divisible by typeSize "
+ "(%zu)", __FUNCTION__, dataBytes, typeSize);
return BAD_VALUE;
}
@@ -219,7 +219,7 @@
jboolean empty = metadata->isEmpty();
- ALOGV("%s: Empty returned %d, entry count was %d",
+ ALOGV("%s: Empty returned %d, entry count was %zu",
__FUNCTION__, empty, metadata->entryCount());
return empty;
@@ -675,7 +675,7 @@
"Could not find section name for key '%s')", key);
return 0;
} else {
- ALOGV("%s: Found matched section '%s' (%d)",
+ ALOGV("%s: Found matched section '%s' (%zu)",
__FUNCTION__, section, sectionIndex);
}