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

Unified Diff: chrome/browser/extensions/api/system_info_storage/storage_info_provider_mac.cc

Issue 10907151: Extensions Docs Server: Enum values do not show up if enum is a type (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: add back braces Created 8 years, 3 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/system_info_storage/storage_info_provider_mac.cc
diff --git a/chrome/browser/extensions/api/system_info_storage/storage_info_provider_mac.cc b/chrome/browser/extensions/api/system_info_storage/storage_info_provider_mac.cc
index 53537d7b5b2243ff20863662aa45d47d8f0591c0..03fff0b29a9ae134ade16755131afddfdcc4e823 100644
--- a/chrome/browser/extensions/api/system_info_storage/storage_info_provider_mac.cc
+++ b/chrome/browser/extensions/api/system_info_storage/storage_info_provider_mac.cc
@@ -79,7 +79,10 @@ bool StorageInfoProviderMac::QueryUnitInfo(const std::string& id,
type = dev_path_to_type_map_[volume_dev].empty() ?
systeminfo::kStorageTypeUnknown : dev_path_to_type_map_[volume_dev];
}
- info->type = type;
+ if (!api::experimental_system_info_storage::
+ GetEnumFromString(type, &info->type)) {
+ return false;
+ }
// TODO(joshuagl): we're reporting different values than Disk Utility.
// Is there an alternative API to get this information that doesn't use
// statfs? NSFileManager's attributesOfFileSystemForPath uses statfs.

Powered by Google App Engine
This is Rietveld 408576698