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

Unified Diff: Source/modules/encryptedmedia/MediaKeys.cpp

Issue 641433002: Implement MediaKeySession.load() (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: initialize variable for Windows Created 6 years, 2 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 | « Source/modules/encryptedmedia/MediaKeySession.idl ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: Source/modules/encryptedmedia/MediaKeys.cpp
diff --git a/Source/modules/encryptedmedia/MediaKeys.cpp b/Source/modules/encryptedmedia/MediaKeys.cpp
index 1a863bf419c282d6cdf44e76f1391354b38570bc..0561cc9d68f1b1870aa6c8d419245d4312c12541 100644
--- a/Source/modules/encryptedmedia/MediaKeys.cpp
+++ b/Source/modules/encryptedmedia/MediaKeys.cpp
@@ -47,16 +47,6 @@
#include "wtf/ArrayBufferView.h"
#include "wtf/RefPtr.h"
-#if ENABLE(ASSERT)
-namespace {
-
-// The list of possible values for |sessionType| passed to createSession().
-const char* kTemporary = "temporary";
-const char* kPersistent = "persistent";
-
-} // namespace
-#endif
-
namespace blink {
static bool isKeySystemSupportedWithContentType(const String& keySystem, const String& contentType)
@@ -243,7 +233,7 @@ MediaKeySession* MediaKeys::createSession(ScriptState* scriptState, const String
// corresponding to the keySystem, throw a DOMException whose name is
// "NotSupportedError".
// FIXME: Check whether sessionType is actually supported by the CDM.
- ASSERT(sessionType == kTemporary || sessionType == kPersistent);
+ ASSERT(MediaKeySession::isValidSessionType(sessionType));
// 2. Let session be a new MediaKeySession object, and initialize it as
// follows:
« no previous file with comments | « Source/modules/encryptedmedia/MediaKeySession.idl ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698