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

Unified Diff: third_party/WebKit/Source/modules/encryptedmedia/MediaKeySession.cpp

Issue 2606633002: encrypted-media tests should not count # of SuspendableObjects (Closed)
Patch Set: temp Created 4 years 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
Index: third_party/WebKit/Source/modules/encryptedmedia/MediaKeySession.cpp
diff --git a/third_party/WebKit/Source/modules/encryptedmedia/MediaKeySession.cpp b/third_party/WebKit/Source/modules/encryptedmedia/MediaKeySession.cpp
index 81fe9241a13a6718febd46f3bc889d39ff60b8b8..69f525fa0372a58181cfa919ac191be62ff1574d 100644
--- a/third_party/WebKit/Source/modules/encryptedmedia/MediaKeySession.cpp
+++ b/third_party/WebKit/Source/modules/encryptedmedia/MediaKeySession.cpp
@@ -40,6 +40,7 @@
#include "modules/encryptedmedia/MediaKeyMessageEvent.h"
#include "modules/encryptedmedia/MediaKeys.h"
#include "platform/ContentDecryptionModuleResult.h"
+#include "platform/InstanceCounters.h"
#include "platform/Timer.h"
#include "platform/network/mime/ContentType.h"
#include "public/platform/WebContentDecryptionModule.h"
@@ -378,6 +379,7 @@ MediaKeySession::MediaKeySession(ScriptState* scriptState,
ClosedPromise::Closed)),
m_actionTimer(this, &MediaKeySession::actionTimerFired) {
DVLOG(MEDIA_KEY_SESSION_LOG_LEVEL) << __func__ << "(" << this << ")";
+ InstanceCounters::incrementCounter(InstanceCounters::MediaKeySessionCounter);
// Create the matching Chromium object. It will not be usable until
// initializeNewSession() is called in response to the user calling
@@ -419,6 +421,7 @@ MediaKeySession::MediaKeySession(ScriptState* scriptState,
MediaKeySession::~MediaKeySession() {
DVLOG(MEDIA_KEY_SESSION_LOG_LEVEL) << __func__ << "(" << this << ")";
+ InstanceCounters::decrementCounter(InstanceCounters::MediaKeySessionCounter);
}
void MediaKeySession::dispose() {
« no previous file with comments | « third_party/WebKit/Source/core/testing/Internals.idl ('k') | third_party/WebKit/Source/modules/encryptedmedia/MediaKeys.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698