Index: chrome/browser/chrome_content_browser_client.cc |
diff --git a/chrome/browser/chrome_content_browser_client.cc b/chrome/browser/chrome_content_browser_client.cc |
index 327f3ac7afc667e00a3fbdc9e7d978a25c53c328..a9558cafac5e65172af9cbfc597ac59181853ef1 100644 |
--- a/chrome/browser/chrome_content_browser_client.cc |
+++ b/chrome/browser/chrome_content_browser_client.cc |
@@ -185,6 +185,7 @@ |
#include "device/usb/public/interfaces/chooser_service.mojom.h" |
#include "device/usb/public/interfaces/device_manager.mojom.h" |
#include "extensions/features/features.h" |
+#include "media/audio/audio_manager.h" |
#include "media/media_features.h" |
#include "net/base/mime_util.h" |
#include "net/base/registry_controlled_domains/registry_controlled_domain.h" |
@@ -1100,8 +1101,10 @@ void ChromeContentBrowserClient::RenderProcessWillLaunch( |
new base::UserDataAdapter<WebRtcLoggingHandlerHost>( |
webrtc_logging_handler_host)); |
+ // The audio manager outlives the host, so it's safe to hand a raw pointer to |
+ // it to the AudioDebugRecordingsHandler, which is owned by the host. |
AudioDebugRecordingsHandler* audio_debug_recordings_handler = |
- new AudioDebugRecordingsHandler(profile); |
+ new AudioDebugRecordingsHandler(profile, media::AudioManager::Get()); |
host->SetUserData( |
AudioDebugRecordingsHandler::kAudioDebugRecordingsHandlerKey, |
new base::UserDataAdapter<AudioDebugRecordingsHandler>( |
@@ -3432,7 +3435,7 @@ bool ChromeContentBrowserClient:: |
"BrowserScheduler", "RedirectNonUINonIOBrowserThreads") == "true"; |
} |
-//static |
+// static |
void ChromeContentBrowserClient::SetDefaultQuotaSettingsForTesting( |
const storage::QuotaSettings* settings) { |
g_default_quota_settings = settings; |