Index: minidump/minidump_crashpad_info_writer.cc |
diff --git a/minidump/minidump_crashpad_info_writer.cc b/minidump/minidump_crashpad_info_writer.cc |
index b60b2e16c6d548001bc5e685d666b7d08c724c63..d8bdb0d36598450cd9071f949cedd842c547b5bc 100644 |
--- a/minidump/minidump_crashpad_info_writer.cc |
+++ b/minidump/minidump_crashpad_info_writer.cc |
@@ -38,6 +38,10 @@ void MinidumpCrashpadInfoWriter::InitializeFromSnapshot( |
DCHECK_EQ(state(), kStateMutable); |
DCHECK(!module_list_); |
+ UUID client_id; |
+ process_snapshot->ClientID(&client_id); |
+ SetClientID(client_id); |
+ |
auto simple_annotations = |
make_scoped_ptr(new MinidumpSimpleStringDictionaryWriter()); |
simple_annotations->InitializeFromMap( |
@@ -54,6 +58,12 @@ void MinidumpCrashpadInfoWriter::InitializeFromSnapshot( |
} |
} |
+void MinidumpCrashpadInfoWriter::SetClientID(const UUID& client_id) { |
+ DCHECK_EQ(state(), kStateMutable); |
+ |
+ crashpad_info_.client_id = client_id; |
+} |
+ |
void MinidumpCrashpadInfoWriter::SetSimpleAnnotations( |
scoped_ptr<MinidumpSimpleStringDictionaryWriter> simple_annotations) { |
DCHECK_EQ(state(), kStateMutable); |
@@ -118,7 +128,9 @@ MinidumpStreamType MinidumpCrashpadInfoWriter::StreamType() const { |
} |
bool MinidumpCrashpadInfoWriter::IsUseful() const { |
- return simple_annotations_ || module_list_; |
+ return crashpad_info_.client_id != UUID() || |
+ simple_annotations_ || |
+ module_list_; |
} |
} // namespace crashpad |