Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(17)

Unified Diff: sql/connection_memory_dump_provider.cc

Issue 2067543003: [tracing] Replace %p with %PRIXPTR in the memory dump names (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: fix include. Created 4 years, 6 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: sql/connection_memory_dump_provider.cc
diff --git a/sql/connection_memory_dump_provider.cc b/sql/connection_memory_dump_provider.cc
index 0284bd0451598da67fb2cddb7b241ba0f6b2d3c6..eaee9b43e3bb8a7601aa32194d09f4cd504d7fcb 100644
--- a/sql/connection_memory_dump_provider.cc
+++ b/sql/connection_memory_dump_provider.cc
@@ -4,6 +4,8 @@
#include "sql/connection_memory_dump_provider.h"
+#include <inttypes.h>
+
#include "base/strings/stringprintf.h"
#include "base/trace_event/process_memory_dump.h"
#include "third_party/sqlite/sqlite3.h"
@@ -53,8 +55,9 @@ bool ConnectionMemoryDumpProvider::OnMemoryDump(
}
std::string name = base::StringPrintf(
- "sqlite/%s_connection/%p",
- connection_name_.empty() ? "Unknown" : connection_name_.c_str(), this);
+ "sqlite/%s_connection/0x%" PRIXPTR,
+ connection_name_.empty() ? "Unknown" : connection_name_.c_str(),
+ reinterpret_cast<uintptr_t>(this));
base::trace_event::MemoryAllocatorDump* dump = pmd->CreateAllocatorDump(name);
dump->AddScalar(base::trace_event::MemoryAllocatorDump::kNameSize,
base::trace_event::MemoryAllocatorDump::kUnitsBytes,
« content/browser/dom_storage/dom_storage_area.cc ('K') | « gin/v8_isolate_memory_dump_provider.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698