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

Unified Diff: minidump/minidump_module_crashpad_info_writer.cc

Issue 674153002: minidump: Change the ownership model (Closed) Base URL: https://chromium.googlesource.com/crashpad/crashpad@master
Patch Set: Address review feedback Created 6 years, 2 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: minidump/minidump_module_crashpad_info_writer.cc
diff --git a/minidump/minidump_module_crashpad_info_writer.cc b/minidump/minidump_module_crashpad_info_writer.cc
index eae793bb4792fbd5da9bce15613b5d8a8b03cccd..a7afbda90b53005992508671e16d6837e17987a1 100644
--- a/minidump/minidump_module_crashpad_info_writer.cc
+++ b/minidump/minidump_module_crashpad_info_writer.cc
@@ -32,10 +32,10 @@ MinidumpModuleCrashpadInfoWriter::~MinidumpModuleCrashpadInfoWriter() {
}
void MinidumpModuleCrashpadInfoWriter::SetSimpleAnnotations(
- MinidumpSimpleStringDictionaryWriter* simple_annotations) {
+ scoped_ptr<MinidumpSimpleStringDictionaryWriter> simple_annotations) {
DCHECK_EQ(state(), kStateMutable);
- simple_annotations_ = simple_annotations;
+ simple_annotations_ = simple_annotations.Pass();
}
bool MinidumpModuleCrashpadInfoWriter::Freeze() {
@@ -65,7 +65,7 @@ MinidumpModuleCrashpadInfoWriter::Children() {
std::vector<MinidumpWritable*> children;
if (simple_annotations_) {
- children.push_back(simple_annotations_);
+ children.push_back(simple_annotations_.get());
}
return children;
@@ -89,10 +89,10 @@ MinidumpModuleCrashpadInfoListWriter::~MinidumpModuleCrashpadInfoListWriter() {
}
void MinidumpModuleCrashpadInfoListWriter::AddModule(
- MinidumpModuleCrashpadInfoWriter* module) {
+ scoped_ptr<MinidumpModuleCrashpadInfoWriter> module) {
DCHECK_EQ(state(), kStateMutable);
- modules_.push_back(module);
+ modules_.push_back(module.release());
}
bool MinidumpModuleCrashpadInfoListWriter::Freeze() {
« no previous file with comments | « minidump/minidump_module_crashpad_info_writer.h ('k') | minidump/minidump_module_crashpad_info_writer_test.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698