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

Unified Diff: chrome/browser/prefs/session_startup_pref.cc

Issue 2777063003: Stop passing raw pointers to base::Value API in c/b/chromeos and c/b/extensions (Closed)
Patch Set: Just rebased Created 3 years, 8 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: chrome/browser/prefs/session_startup_pref.cc
diff --git a/chrome/browser/prefs/session_startup_pref.cc b/chrome/browser/prefs/session_startup_pref.cc
index b7dd90f45765b50a944b4e4552eb53d5a55c807c..9126203deeba9a3b95501a654cc9d16baccc036e 100644
--- a/chrome/browser/prefs/session_startup_pref.cc
+++ b/chrome/browser/prefs/session_startup_pref.cc
@@ -8,6 +8,7 @@
#include <string>
+#include "base/memory/ptr_util.h"
#include "base/values.h"
#include "build/build_config.h"
#include "chrome/browser/profiles/profile.h"
@@ -90,7 +91,7 @@ void SessionStartupPref::SetStartupPref(PrefService* prefs,
url_pref_list->Clear();
for (size_t i = 0; i < pref.urls.size(); ++i) {
url_pref_list->Set(static_cast<int>(i),
- new base::Value(pref.urls[i].spec()));
+ base::MakeUnique<base::Value>(pref.urls[i].spec()));
}
}
}

Powered by Google App Engine
This is Rietveld 408576698