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

Unified Diff: net/base/mime_util.h

Issue 1134393002: Implement ChromeOS mime type extension mappings. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Flag guard two test cases for ChromeOS. Created 5 years, 7 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: net/base/mime_util.h
diff --git a/net/base/mime_util.h b/net/base/mime_util.h
index 80f440ef3e0adc990e121c2f4a608e40608f7e87..63c77aadff9ccdbc0e814989e82044e2b702e7a3 100644
--- a/net/base/mime_util.h
+++ b/net/base/mime_util.h
@@ -166,6 +166,16 @@ NET_EXPORT void AddMultipartFinalDelimiterForUpload(
const std::string& mime_boundary,
std::string* post_data);
+struct MimeInfo {
+ const char* const mime_type;
+ const char* const extensions; // comma separated list
+};
+
+// Find mime type of |ext| from |mapping|.
eroman 2015/05/18 15:45:24 Find --> Finds |mapping| --> |mappings|
yawano 2015/05/19 02:26:40 Done.
+const char* FindMimeType(const MimeInfo* mappings,
+ size_t mappings_len,
+ const char* ext);
+
} // namespace net
#endif // NET_BASE_MIME_UTIL_H__

Powered by Google App Engine
This is Rietveld 408576698