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

Unified Diff: media/blink/cdm_session_adapter.cc

Issue 2078833004: Change back to destroy the CDM synchronously (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@2743
Patch Set: Created 4 years, 6 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 | « no previous file | third_party/WebKit/Source/modules/encryptedmedia/ContentDecryptionModuleResultPromise.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: media/blink/cdm_session_adapter.cc
diff --git a/media/blink/cdm_session_adapter.cc b/media/blink/cdm_session_adapter.cc
index 0a743e08ef305df411f4a6b12d6a6ca7676793ba..2350ba246745f0f0118035a54961537fa410b659 100644
--- a/media/blink/cdm_session_adapter.cc
+++ b/media/blink/cdm_session_adapter.cc
@@ -26,26 +26,12 @@ namespace {
const char kMediaEME[] = "Media.EME.";
const char kDot[] = ".";
const char kTimeToCreateCdmUMAName[] = "CreateCdmTime";
-
-void ReleaseCdm(scoped_refptr<MediaKeys> cdm) {
- // |cdm| will be freed now.
-}
-
} // namespace
CdmSessionAdapter::CdmSessionAdapter()
: trace_id_(0), weak_ptr_factory_(this) {}
-CdmSessionAdapter::~CdmSessionAdapter() {
- // Freeing |cdm_| may take a while, so post a task to do it asynchronously.
- // Note that freeing the CDM will cause any unfullfilled promises to be
- // rejected, and that needs to be done outside of blink gc (which most
- // likely triggered our destruction).
- if (cdm_) {
- base::ThreadTaskRunnerHandle::Get()->PostTask(
- FROM_HERE, base::Bind(&ReleaseCdm, cdm_));
- }
-}
+CdmSessionAdapter::~CdmSessionAdapter() {}
void CdmSessionAdapter::CreateCdm(
CdmFactory* cdm_factory,
« no previous file with comments | « no previous file | third_party/WebKit/Source/modules/encryptedmedia/ContentDecryptionModuleResultPromise.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698