summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--build/features_override.gypi1
-rw-r--r--net/base/mime_util.cc8
2 files changed, 6 insertions, 3 deletions
diff --git a/build/features_override.gypi b/build/features_override.gypi
index 1dc65db..82708ac 100644
--- a/build/features_override.gypi
+++ b/build/features_override.gypi
@@ -41,6 +41,7 @@
'ENABLE_METER_TAG=1',
'ENABLE_MEDIA_STATISTICS=1',
'ENABLE_MEDIA_STREAM=1',
+ 'ENABLE_MHTML=1',
'ENABLE_NOTIFICATIONS=1',
'ENABLE_OFFLINE_WEB_APPLICATIONS=1',
'ENABLE_OPENTYPE_SANITIZER=1',
diff --git a/net/base/mime_util.cc b/net/base/mime_util.cc
index 51bf964..b6aa539 100644
--- a/net/base/mime_util.cc
+++ b/net/base/mime_util.cc
@@ -117,7 +117,8 @@ static const MimeInfo secondary_mappings[] = {
{ "application/rdf+xml", "rdf" },
{ "text/xml", "xsl,xbl" },
{ "application/vnd.mozilla.xul+xml", "xul" },
- { "application/x-shockwave-flash", "swf,swl" }
+ { "application/x-shockwave-flash", "swf,swl" },
+ { "multipart/related", "mht,mhtml" }
};
static const char* FindMimeType(const MimeInfo* mappings,
@@ -266,12 +267,13 @@ static const char* const supported_non_image_types[] = {
"application/atom+xml",
"application/json",
"application/x-x509-user-cert",
+ "multipart/related", // For MHTML support.
"multipart/x-mixed-replace"
// Note: ADDING a new type here will probably render it AS HTML. This can
// result in cross site scripting.
};
-COMPILE_ASSERT(arraysize(supported_non_image_types) == 16,
- supported_non_images_types_must_equal_16);
+COMPILE_ASSERT(arraysize(supported_non_image_types) == 17,
+ supported_non_images_types_must_equal_17);
// Mozilla 1.8 and WinIE 7 both accept text/javascript and text/ecmascript.
// Mozilla 1.8 accepts application/javascript, application/ecmascript, and