Bug 1111190 - Fix sign-compare warnings in CollectIonReports; r=froydnj
We only use kNumFields to compare it to the result of int sscanf(...).
--- a/xpcom/base/SystemMemoryReporter.cpp
+++ b/xpcom/base/SystemMemoryReporter.cpp
@@ -713,17 +713,17 @@ private:
// The first three fields of each entry interest us:
// 1) client - Essentially the process name. We limit client names to 63
// characters, in theory they should never be greater than 15
// due to thread name length limitations.
// 2) pid - The ID of the allocating process, read as a uint32_t.
// 3) size - The size of the allocation in bytes, read as as a uint64_t.
const char* const kFormatString = "%63s %" SCNu32 " %" SCNu64;
- const size_t kNumFields = 3;
+ const int kNumFields = 3;
const size_t kStringSize = 64;
const char* const kIonIommuPath = "/sys/kernel/debug/ion/iommu";
FILE* iommu = fopen(kIonIommuPath, "r");
if (!iommu) {
if (NS_WARN_IF(errno != ENOENT)) {
return NS_ERROR_FAILURE;
}