Commit 9ee0c035 authored by xhwang's avatar xhwang Committed by Commit bot

Remove incorrect promise resolving type handling.

This partially reverts commit fd0069d6.

Issue 408330 has been fixed with a CDM update. This error handling code is not
needed anymore.

TBR=dmichael@chromium.org
BUG=408337

Review URL: https://codereview.chromium.org/594673002

Cr-Commit-Position: refs/heads/master@{#297008}
parent d484d41c
...@@ -700,19 +700,6 @@ bool ContentDecryptorDelegate::DecryptAndDecodeVideo( ...@@ -700,19 +700,6 @@ bool ContentDecryptorDelegate::DecryptAndDecodeVideo(
void ContentDecryptorDelegate::OnPromiseResolved(uint32 promise_id) { void ContentDecryptorDelegate::OnPromiseResolved(uint32 promise_id) {
scoped_ptr<CdmPromise> promise = TakePromise(promise_id); scoped_ptr<CdmPromise> promise = TakePromise(promise_id);
// Special case due to http://crbug.com/408330. CDM is resolving LoadSession()
// with this method when the session is not found. Instead it should call
// PromiseResolvedWithSession(""), so emulate that here until 408330 is fixed.
// TODO(jrummell): Remove this code when the CDM is updated.
if (promise &&
promise->GetResolveParameterType() == media::CdmPromise::STRING_TYPE) {
NewSessionCdmPromise* session_promise =
static_cast<NewSessionCdmPromise*>(promise.get());
session_promise->resolve(std::string());
return;
}
if (!promise || if (!promise ||
promise->GetResolveParameterType() != media::CdmPromise::VOID_TYPE) { promise->GetResolveParameterType() != media::CdmPromise::VOID_TYPE) {
NOTREACHED(); NOTREACHED();
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment