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

Unified Diff: chrome/browser/extensions/api/sync_file_system/sync_file_system_api_helpers.cc

Issue 2806283002: Revert of Stop passing raw pointers to base::Value API in c/b/chromeos and c/b/extensions (Closed)
Patch Set: 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/extensions/api/sync_file_system/sync_file_system_api_helpers.cc
diff --git a/chrome/browser/extensions/api/sync_file_system/sync_file_system_api_helpers.cc b/chrome/browser/extensions/api/sync_file_system/sync_file_system_api_helpers.cc
index c191b3d18a96a86eda90b25b611d32034b43009c..6cfbf8a18624f63dac91d052c1e69ffe49797346 100644
--- a/chrome/browser/extensions/api/sync_file_system/sync_file_system_api_helpers.cc
+++ b/chrome/browser/extensions/api/sync_file_system/sync_file_system_api_helpers.cc
@@ -5,8 +5,6 @@
#include "chrome/browser/extensions/api/sync_file_system/sync_file_system_api_helpers.h"
#include "base/logging.h"
-#include "base/memory/ptr_util.h"
-#include "base/values.h"
#include "storage/browser/fileapi/file_system_url.h"
#include "storage/common/fileapi/file_system_util.h"
@@ -107,11 +105,11 @@
return api::sync_file_system::CONFLICT_RESOLUTION_POLICY_NONE;
}
-std::unique_ptr<base::DictionaryValue> CreateDictionaryValueForFileSystemEntry(
+base::DictionaryValue* CreateDictionaryValueForFileSystemEntry(
const storage::FileSystemURL& url,
sync_file_system::SyncFileType file_type) {
if (!url.is_valid() || file_type == sync_file_system::SYNC_FILE_TYPE_UNKNOWN)
- return nullptr;
+ return NULL;
std::string file_path =
base::FilePath(storage::VirtualPath::GetNormalizedFilePath(url.path()))
@@ -124,7 +122,7 @@
root_url.append("/");
}
- auto dict = base::MakeUnique<base::DictionaryValue>();
+ base::DictionaryValue* dict = new base::DictionaryValue;
dict->SetString("fileSystemType",
storage::GetFileSystemTypeString(url.mount_type()));
dict->SetString("fileSystemName",

Powered by Google App Engine
This is Rietveld 408576698