Skip to content

Commit

Permalink
Bug 1159495 - Only report Adobe EME supported if required WMF codecs …
Browse files Browse the repository at this point in the history
…are installed. r=edwin, a=sledru
  • Loading branch information
Chris Pearce committed Apr 29, 2015
1 parent ce4bbd1 commit 4b9c7f0
Showing 1 changed file with 6 additions and 0 deletions.
6 changes: 6 additions & 0 deletions dom/media/eme/MediaKeySystemAccess.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,7 @@
#endif
#ifdef XP_WIN
#include "mozilla/WindowsVersion.h"
#include "WMFDecoderModule.h"
#endif
#include "nsContentCID.h"
#include "nsServiceManagerUtils.h"
Expand Down Expand Up @@ -155,6 +156,11 @@ MediaKeySystemAccess::GetKeySystemStatus(const nsAString& aKeySystem,
if (!Preferences::GetBool("media.gmp-eme-adobe.enabled", false)) {
return MediaKeySystemStatus::Cdm_disabled;
}
if (!WMFDecoderModule::HasH264() || !WMFDecoderModule::HasAAC()) {
// The system doesn't have the codecs that Adobe EME relies
// on installed.
return MediaKeySystemStatus::Cdm_not_supported;
}
if (!HaveGMPFor(mps,
NS_ConvertUTF16toUTF8(aKeySystem),
NS_LITERAL_CSTRING(GMP_API_DECRYPTOR)) &&
Expand Down

0 comments on commit 4b9c7f0

Please sign in to comment.