Bug 1147226 - Ensure media.eme.mse-only is honoured in HTMLMediaElement::MetadataLoaded(). r=edwin
authorChris Pearce <cpearce@mozilla.com>
Wed, 25 Mar 2015 15:00:26 +1300
changeset 235486 3779bb7888d3
parent 235485 bb0db528a2c4
child 235487 0b02e059cf60
push id28473
push userryanvm@gmail.com
push date2015-03-25 14:34 +0000
treeherdermozilla-central@eb3e4c2fa35e [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewersedwin
bugs1147226
milestone39.0a1
first release with
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
last release without
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
Bug 1147226 - Ensure media.eme.mse-only is honoured in HTMLMediaElement::MetadataLoaded(). r=edwin
dom/html/HTMLMediaElement.cpp
--- a/dom/html/HTMLMediaElement.cpp
+++ b/dom/html/HTMLMediaElement.cpp
@@ -3079,17 +3079,17 @@ void HTMLMediaElement::MetadataLoaded(co
     DispatchAsyncEvent(NS_LITERAL_STRING("resize"));
   }
   DispatchAsyncEvent(NS_LITERAL_STRING("loadedmetadata"));
   if (mDecoder && mDecoder->IsTransportSeekable() && mDecoder->IsMediaSeekable()) {
     ProcessMediaFragmentURI();
     mDecoder->SetFragmentEndTime(mFragmentEnd);
   }
   if (mIsEncrypted) {
-    if (!mMediaSource) {
+    if (!mMediaSource && Preferences::GetBool("media.eme.mse-only", true)) {
       DecodeError();
       return;
     }
 
 #ifdef MOZ_EME
     DispatchEncrypted(aInfo->mCrypto.mInitData, aInfo->mCrypto.mType);
 #endif
   }