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

Unified Diff: base/trace_event/memory_dump_manager.cc

Issue 1344543002: [tracing] Expose level of detail of memory dumps in the trace JSON (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@cleanup_levdetail
Patch Set: Created 5 years, 3 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
« no previous file with comments | « no previous file | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: base/trace_event/memory_dump_manager.cc
diff --git a/base/trace_event/memory_dump_manager.cc b/base/trace_event/memory_dump_manager.cc
index 0ab253d9f9e194c5401d789dc38ebfe08e2ca988..a2fa95396360caad11ccf78d58c19457f9f42098 100644
--- a/base/trace_event/memory_dump_manager.cc
+++ b/base/trace_event/memory_dump_manager.cc
@@ -367,9 +367,12 @@ void MemoryDumpManager::FinalizeDumpAndAddToTrace(
return;
}
- scoped_refptr<ConvertableToTraceFormat> event_value(new TracedValue());
- pmd_async_state->process_memory_dump.AsValueInto(
- static_cast<TracedValue*>(event_value.get()));
+ TracedValue* traced_value = new TracedValue();
+ scoped_refptr<ConvertableToTraceFormat> event_value(traced_value);
+ pmd_async_state->process_memory_dump.AsValueInto(traced_value);
+ traced_value->SetString("level_of_detail",
+ MemoryDumpLevelOfDetailToString(
+ pmd_async_state->req_args.level_of_detail));
const char* const event_name =
MemoryDumpTypeToString(pmd_async_state->req_args.dump_type);
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698