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

Unified Diff: media/test/data/eme_player_js/utils.js

Issue 1717033002: EME: Fix the CDM File IO test when run using unprefixed EME. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 4 years, 10 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 | « media/test/data/eme_player_js/player_utils.js ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: media/test/data/eme_player_js/utils.js
diff --git a/media/test/data/eme_player_js/utils.js b/media/test/data/eme_player_js/utils.js
index 00e23ac44ca28be592c046127a40d2b1507f2e93..41a4d45c322855e4a3dd3e57e660582f4ddd1796 100644
--- a/media/test/data/eme_player_js/utils.js
+++ b/media/test/data/eme_player_js/utils.js
@@ -175,7 +175,7 @@ Utils.getHexString = function(uintArray) {
};
Utils.hasPrefix = function(msg, prefix) {
- var message = String.fromCharCode.apply(null, msg);
+ var message = String.fromCharCode.apply(null, Utils.convertToUint8Array(msg));
ddorwin 2016/02/20 00:09:10 Since there is no way to assert that a Uint8Array
return message.substring(0, prefix.length) == prefix;
};
@@ -199,8 +199,7 @@ Utils.isRenewalMessage = function(message) {
// For the prefixed API renewal messages are determined by looking at the
// message and finding a known string.
Utils.isRenewalMessagePrefixed = function(msg) {
- return Utils.hasPrefix(Utils.convertToUint8Array(msg),
- PREFIXED_EME_RENEWAL_MESSAGE_HEADER);
+ return Utils.hasPrefix(msg, PREFIXED_EME_RENEWAL_MESSAGE_HEADER);
};
Utils.resetTitleChange = function() {
« no previous file with comments | « media/test/data/eme_player_js/player_utils.js ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698