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

Unified Diff: media/audio/audio_manager.h

Issue 1036703002: Add a hang monitor for the audio thread. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Disable for OSX. Created 5 years, 9 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 | « content/browser/browser_main_loop.cc ('k') | media/audio/audio_manager.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: media/audio/audio_manager.h
diff --git a/media/audio/audio_manager.h b/media/audio/audio_manager.h
index 7705cdb804ee516b254beb0fe8d35d51a61f738c..5e49b8b399afd138c35f659d73823be06a0e9567 100644
--- a/media/audio/audio_manager.h
+++ b/media/audio/audio_manager.h
@@ -34,6 +34,13 @@ class MEDIA_EXPORT AudioManager {
// such |audio_log_factory| must outlive the AudioManager.
static AudioManager* Create(AudioLogFactory* audio_log_factory);
+ // Similar to Create() except also schedules a monitor on the given task
+ // runner to ensure the audio thread is not stuck for more than 60 seconds; if
+ // a hang is detected, the process will be crashed.
+ static AudioManager* CreateWithHangTimer(
+ AudioLogFactory* audio_log_factory,
+ const scoped_refptr<base::SingleThreadTaskRunner>& monitor_task_runner);
+
// Similar to Create() except uses a FakeAudioLogFactory for testing.
static AudioManager* CreateForTesting();
« no previous file with comments | « content/browser/browser_main_loop.cc ('k') | media/audio/audio_manager.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698