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

Unified Diff: extensions/utility/unpacker.cc

Issue 1394993004: Make ValueDeserializer::Deserialize return scoped_ptr (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Fix and add todo about not failed trybot Created 5 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
« no previous file with comments | « extensions/common/manifest_test.cc ('k') | google_apis/drive/test_util.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: extensions/utility/unpacker.cc
diff --git a/extensions/utility/unpacker.cc b/extensions/utility/unpacker.cc
index 6e28a49b31a2c301a3f1dfe256a9d93cb4aed19d..f499808580adb5ecf004d42d25621e3928eecdf7 100644
--- a/extensions/utility/unpacker.cc
+++ b/extensions/utility/unpacker.cc
@@ -121,7 +121,7 @@ scoped_ptr<base::DictionaryValue> Unpacker::ReadManifest() {
JSONFileValueDeserializer deserializer(manifest_path);
std::string error;
- scoped_ptr<base::Value> root(deserializer.Deserialize(NULL, &error));
+ scoped_ptr<base::Value> root = deserializer.Deserialize(NULL, &error);
if (!root.get()) {
SetError(error);
return NULL;
@@ -253,8 +253,8 @@ bool Unpacker::AddDecodedImage(const base::FilePath& path) {
bool Unpacker::ReadMessageCatalog(const base::FilePath& message_path) {
std::string error;
JSONFileValueDeserializer deserializer(message_path);
- scoped_ptr<base::DictionaryValue> root = base::DictionaryValue::From(
- make_scoped_ptr(deserializer.Deserialize(NULL, &error)));
+ scoped_ptr<base::DictionaryValue> root =
+ base::DictionaryValue::From(deserializer.Deserialize(NULL, &error));
if (!root.get()) {
base::string16 messages_file = message_path.LossyDisplayName();
if (error.empty()) {
« no previous file with comments | « extensions/common/manifest_test.cc ('k') | google_apis/drive/test_util.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698