[Bug 26678] New: MediaKeySession.generateRequest() should not fail if callable is false

https://www.w3.org/Bugs/Public/show_bug.cgi?id=26678

            Bug ID: 26678
           Summary: MediaKeySession.generateRequest() should not fail if
                    callable is false
           Product: HTML WG
           Version: unspecified
          Hardware: PC
                OS: Windows NT
            Status: NEW
          Severity: normal
          Priority: P2
         Component: Encrypted Media Extensions
          Assignee: adrianba@microsoft.com
          Reporter: cpearce@mozilla.com
        QA Contact: public-html-bugzilla@w3.org
                CC: ddorwin@google.com, mike@w3.org,
                    public-html-media@w3.org

The spec for MediaKeySession.generateRequest() is:

<quote>

The generateRequest(initDataType, initData) method creates a new
MediaKeySession object for the initData. It must run the following steps:

The contents of initData are container-specific Initialization Data.
initDataType is the initialization data type that indicates how to interpret
initData.

    If this object's callable value is false, return a promise rejected with a
new DOMException whose name is "InvalidStateError".

</quote>

callable is set to true after the request is sent.

https://dvcs.w3.org/hg/html-media/raw-file/default/encrypted-media/encrypted-media.html#dom-generaterequest

Since generateRequest() is the only thing that sets callable to true, and it
aborts if callable is false, nothing else will ever set callable to true, so no
function will be usable.

I think this must be a copy-paste error, and the "If this object's callable
value is false" step should be removed from generateRequest().

-- 
You are receiving this mail because:
You are on the CC list for the bug.

Received on Tuesday, 26 August 2014 22:46:16 UTC