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

Unified Diff: media/mojo/services/test_mojo_media_client.cc

Issue 2784433002: Ensures that audio tasks cannot run after AudioManager is deleted. (Closed)
Patch Set: rebase Created 3 years, 7 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/mojo/services/test_mojo_media_client.h ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: media/mojo/services/test_mojo_media_client.cc
diff --git a/media/mojo/services/test_mojo_media_client.cc b/media/mojo/services/test_mojo_media_client.cc
index f47188b94676114f17a348351d3c1fa6f22e31a5..1e380c1f527a177b74c422fde8c908d18d16a680 100644
--- a/media/mojo/services/test_mojo_media_client.cc
+++ b/media/mojo/services/test_mojo_media_client.cc
@@ -11,6 +11,7 @@
#include "media/audio/audio_device_description.h"
#include "media/audio/audio_manager.h"
#include "media/audio/audio_output_stream_sink.h"
+#include "media/audio/audio_thread_impl.h"
#include "media/base/cdm_factory.h"
#include "media/base/media.h"
#include "media/base/media_log.h"
@@ -42,7 +43,7 @@ void TestMojoMediaClient::Initialize(
AudioManager* audio_manager = AudioManager::Get();
if (!audio_manager) {
audio_manager_ = media::AudioManager::CreateForTesting(
- base::ThreadTaskRunnerHandle::Get());
+ base::MakeUnique<AudioThreadImpl>());
audio_manager = audio_manager_.get();
// Flush the message loop to ensure that the audio manager is initialized.
base::RunLoop().RunUntilIdle();
« no previous file with comments | « media/mojo/services/test_mojo_media_client.h ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698