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 265786 3779bb7888d30232e88dc0d71afa6061ba1be85b
parent 265785 bb0db528a2c4fb1d155ea108d30870bba86263c2
child 265787 0b02e059cf6031ff7047d3075b9e0ed40ab89a33
push id830
push userraliiev@mozilla.com
push dateFri, 19 Jun 2015 19:24:37 +0000
treeherdermozilla-release@932614382a68 [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
   }