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

Unified Diff: content/renderer/renderer_webkitplatformsupport_impl.cc

Issue 228823003: Adding check for MIME types that do not take codecs parameter (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: addressing comments Created 6 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
« no previous file with comments | « content/browser/media/media_canplaytype_browsertest.cc ('k') | net/base/mime_util.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: content/renderer/renderer_webkitplatformsupport_impl.cc
diff --git a/content/renderer/renderer_webkitplatformsupport_impl.cc b/content/renderer/renderer_webkitplatformsupport_impl.cc
index ca92d5e5568cd56aa2d2c99ab959a19ddc66828d..627b762e12bce64318955ba5544e116ffa13ddea 100644
--- a/content/renderer/renderer_webkitplatformsupport_impl.cc
+++ b/content/renderer/renderer_webkitplatformsupport_impl.cc
@@ -432,18 +432,17 @@ RendererWebKitPlatformSupportImpl::MimeRegistry::supportsMediaMIMEType(
// Check list of strict codecs to see if it is supported.
if (net::IsStrictMediaMimeType(mime_type_ascii)) {
- // We support the container, but no codecs were specified.
- if (codecs.isNull())
- return MayBeSupported;
-
// Check if the codecs are a perfect match.
std::vector<std::string> strict_codecs;
net::ParseCodecString(ToASCIIOrEmpty(codecs), &strict_codecs, false);
- if (!net::IsSupportedStrictMediaMimeType(mime_type_ascii, strict_codecs))
- return IsNotSupported;
+ if (net::IsSupportedStrictMediaMimeType(mime_type_ascii, strict_codecs))
Ryan Sleevi 2014/04/18 01:57:41 How does this work without you also requiring to c
amogh.bihani 2014/04/21 06:10:56 I'm sorry I missed this. I did test this code. The
+ return IsSupported;
- // Good to go!
- return IsSupported;
+ // We support the container, but no codecs were specified.
+ if (codecs.isNull())
+ return MayBeSupported;
+
+ return IsNotSupported;
}
// If we don't recognize the codec, it's possible we support it.
« no previous file with comments | « content/browser/media/media_canplaytype_browsertest.cc ('k') | net/base/mime_util.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698