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

Unified Diff: media/base/android/media_service_throttler.cc

Issue 2668813002: Remove LazyInstance usage from media/ (Closed)
Patch Set: Fix presubmit comments. Created 3 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/base/android/media_service_throttler.h ('k') | media/base/key_systems.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: media/base/android/media_service_throttler.cc
diff --git a/media/base/android/media_service_throttler.cc b/media/base/android/media_service_throttler.cc
index f30c71ec701820bda990956fbef45684aebd798f..3a46dd93006d8c40312444dd9d1d3671855236c6 100644
--- a/media/base/android/media_service_throttler.cc
+++ b/media/base/android/media_service_throttler.cc
@@ -14,9 +14,6 @@ namespace media {
namespace {
-static base::LazyInstance<MediaServiceThrottler>::Leaky
- g_media_service_throttler = LAZY_INSTANCE_INITIALIZER;
-
// Period of inactivity after which we stop listening for MediaServer crashes.
// NOTE: Server crashes don't count as acticity. Only calls to
// GetDelayForClientCreation() do.
@@ -84,7 +81,8 @@ const base::TimeDelta kMinDelayWindow =
// static
MediaServiceThrottler* MediaServiceThrottler::GetInstance() {
- return g_media_service_throttler.Pointer();
+ static MediaServiceThrottler* instance = new MediaServiceThrottler();
+ return instance;
}
MediaServiceThrottler::~MediaServiceThrottler() {}
« no previous file with comments | « media/base/android/media_service_throttler.h ('k') | media/base/key_systems.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698