diff --git a/minidump/minidump_location_descriptor_list_writer_test.cc b/minidump/minidump_location_descriptor_list_writer_test.cc index 53a1272a..00743063 100644 --- a/minidump/minidump_location_descriptor_list_writer_test.cc +++ b/minidump/minidump_location_descriptor_list_writer_test.cc @@ -14,6 +14,7 @@ #include "minidump/minidump_location_descriptor_list_writer.h" +#include "base/format_macros.h" #include "base/strings/stringprintf.h" #include "gtest/gtest.h" #include "minidump/test/minidump_location_descriptor_list_test_util.h" @@ -95,7 +96,7 @@ TEST(MinidumpLocationDescriptorListWriter, ThreeChildren) { ASSERT_TRUE(list); for (size_t index = 0; index < arraysize(kValues); ++index) { - SCOPED_TRACE(base::StringPrintf("index %zu", index)); + SCOPED_TRACE(base::StringPrintf("index %" PRIuS, index)); const uint32_t* child = MinidumpWritableAtLocationDescriptor( file_writer.string(), list->children[index]); diff --git a/minidump/minidump_memory_writer_test.cc b/minidump/minidump_memory_writer_test.cc index 1aee35de..e77a0648 100644 --- a/minidump/minidump_memory_writer_test.cc +++ b/minidump/minidump_memory_writer_test.cc @@ -19,6 +19,7 @@ #include #include "base/basictypes.h" +#include "base/format_macros.h" #include "base/strings/stringprintf.h" #include "gtest/gtest.h" #include "minidump/minidump_extensions.h" @@ -347,7 +348,7 @@ TEST(MinidumpMemoryWriter, AddFromSnapshot) { ASSERT_EQ(3u, memory_list->NumberOfMemoryRanges); for (size_t index = 0; index < memory_list->NumberOfMemoryRanges; ++index) { - SCOPED_TRACE(base::StringPrintf("index %zu", index)); + SCOPED_TRACE(base::StringPrintf("index %" PRIuS, index)); ExpectMinidumpMemoryDescriptorAndContents( &expect_memory_descriptors[index], &memory_list->MemoryRanges[index], diff --git a/minidump/minidump_module_writer_test.cc b/minidump/minidump_module_writer_test.cc index 881f33c5..dd104a5a 100644 --- a/minidump/minidump_module_writer_test.cc +++ b/minidump/minidump_module_writer_test.cc @@ -20,6 +20,7 @@ #include #include +#include "base/format_macros.h" #include "base/strings/stringprintf.h" #include "base/strings/utf_string_conversions.h" #include "gtest/gtest.h" @@ -729,7 +730,7 @@ TEST(MinidumpModuleWriter, InitializeFromSnapshot) { ASSERT_EQ(3u, module_list->NumberOfModules); for (size_t index = 0; index < module_list->NumberOfModules; ++index) { - SCOPED_TRACE(base::StringPrintf("index %zu", index)); + SCOPED_TRACE(base::StringPrintf("index %" PRIuS, index)); ASSERT_NO_FATAL_FAILURE(ExpectModule(&expect_modules[index], &module_list->Modules[index], file_writer.string(), diff --git a/minidump/minidump_rva_list_writer_test.cc b/minidump/minidump_rva_list_writer_test.cc index e2b7d122..0754748a 100644 --- a/minidump/minidump_rva_list_writer_test.cc +++ b/minidump/minidump_rva_list_writer_test.cc @@ -14,6 +14,7 @@ #include "minidump/minidump_rva_list_writer.h" +#include "base/format_macros.h" #include "base/strings/stringprintf.h" #include "gtest/gtest.h" #include "minidump/test/minidump_rva_list_test_util.h" @@ -87,7 +88,7 @@ TEST(MinidumpRVAListWriter, ThreeChildren) { ASSERT_TRUE(list); for (size_t index = 0; index < arraysize(kValues); ++index) { - SCOPED_TRACE(base::StringPrintf("index %zu", index)); + SCOPED_TRACE(base::StringPrintf("index %" PRIuS, index)); const uint32_t* child = MinidumpWritableAtRVA( file_writer.string(), list->children[index]); diff --git a/minidump/minidump_string_writer_test.cc b/minidump/minidump_string_writer_test.cc index 730d5fed..2bc87180 100644 --- a/minidump/minidump_string_writer_test.cc +++ b/minidump/minidump_string_writer_test.cc @@ -22,6 +22,7 @@ #include "base/basictypes.h" #include "base/compiler_specific.h" +#include "base/format_macros.h" #include "base/strings/string16.h" #include "base/strings/stringprintf.h" #include "base/strings/utf_string_conversions.h" @@ -73,7 +74,7 @@ TEST(MinidumpStringWriter, MinidumpUTF16StringWriter) { for (size_t index = 0; index < arraysize(kTestData); ++index) { SCOPED_TRACE(base::StringPrintf( - "index %zu, input %s", index, kTestData[index].input_string)); + "index %" PRIuS ", input %s", index, kTestData[index].input_string)); // Make sure that the expected output string with its NUL terminator fits in // the space provided. @@ -120,8 +121,8 @@ TEST(MinidumpStringWriter, ConvertInvalidUTF8ToUTF16) { }; for (size_t index = 0; index < arraysize(kTestData); ++index) { - SCOPED_TRACE( - base::StringPrintf("index %zu, input %s", index, kTestData[index])); + SCOPED_TRACE(base::StringPrintf( + "index %" PRIuS ", input %s", index, kTestData[index])); file_writer.Reset(); crashpad::internal::MinidumpUTF16StringWriter string_writer; string_writer.SetUTF8(kTestData[index]); @@ -183,7 +184,7 @@ TEST(MinidumpStringWriter, MinidumpUTF8StringWriter) { for (size_t index = 0; index < arraysize(kTestData); ++index) { SCOPED_TRACE(base::StringPrintf( - "index %zu, input %s", index, kTestData[index].string)); + "index %" PRIuS ", input %s", index, kTestData[index].string)); file_writer.Reset(); crashpad::internal::MinidumpUTF8StringWriter string_writer; diff --git a/minidump/minidump_thread_writer_test.cc b/minidump/minidump_thread_writer_test.cc index f8fd43b4..3f41c7c0 100644 --- a/minidump/minidump_thread_writer_test.cc +++ b/minidump/minidump_thread_writer_test.cc @@ -19,6 +19,7 @@ #include #include "base/compiler_specific.h" +#include "base/format_macros.h" #include "base/strings/stringprintf.h" #include "gtest/gtest.h" #include "minidump/minidump_context_writer.h" @@ -619,7 +620,7 @@ void RunInitializeFromSnapshotTest(bool thread_id_collision) { size_t memory_index = 0; for (size_t index = 0; index < thread_list->NumberOfThreads; ++index) { - SCOPED_TRACE(base::StringPrintf("index %zu", index)); + SCOPED_TRACE(base::StringPrintf("index %" PRIuS, index)); const MINIDUMP_MEMORY_DESCRIPTOR* observed_stack = nullptr; const MINIDUMP_MEMORY_DESCRIPTOR** observed_stack_p = diff --git a/minidump/test/minidump_context_test_util.cc b/minidump/test/minidump_context_test_util.cc index b410cd5c..a0e06400 100644 --- a/minidump/test/minidump_context_test_util.cc +++ b/minidump/test/minidump_context_test_util.cc @@ -15,6 +15,7 @@ #include "minidump/test/minidump_context_test_util.h" #include "base/basictypes.h" +#include "base/format_macros.h" #include "base/strings/stringprintf.h" #include "gtest/gtest.h" #include "snapshot/cpu_context.h" @@ -183,7 +184,7 @@ void ExpectMinidumpContextFxsave(const FxsaveType* expected, for (size_t st_mm_index = 0; st_mm_index < arraysize(expected->st_mm); ++st_mm_index) { - SCOPED_TRACE(base::StringPrintf("st_mm_index %zu", st_mm_index)); + SCOPED_TRACE(base::StringPrintf("st_mm_index %" PRIuS, st_mm_index)); for (size_t byte = 0; byte < arraysize(expected->st_mm[st_mm_index].st); ++byte) { @@ -201,7 +202,7 @@ void ExpectMinidumpContextFxsave(const FxsaveType* expected, for (size_t xmm_index = 0; xmm_index < arraysize(expected->xmm); ++xmm_index) { - SCOPED_TRACE(base::StringPrintf("xmm_index %zu", xmm_index)); + SCOPED_TRACE(base::StringPrintf("xmm_index %" PRIuS, xmm_index)); for (size_t byte = 0; byte < arraysize(expected->xmm[xmm_index]); ++byte) { EXPECT_EQ(expected->xmm[xmm_index][byte], observed->xmm[xmm_index][byte]) << "byte " << byte;