| Index: media/audio/audio_output_dispatcher_impl.cc
|
| diff --git a/media/audio/audio_output_dispatcher_impl.cc b/media/audio/audio_output_dispatcher_impl.cc
|
| index f50748c905d5071865ce01c32f7309f1b9c3b9d7..b538acde82cdb67b8a9117f0ba4b530091a2ddcc 100644
|
| --- a/media/audio/audio_output_dispatcher_impl.cc
|
| +++ b/media/audio/audio_output_dispatcher_impl.cc
|
| @@ -32,6 +32,12 @@ AudioOutputDispatcherImpl::AudioOutputDispatcherImpl(
|
| audio_stream_id_(0) {}
|
|
|
| AudioOutputDispatcherImpl::~AudioOutputDispatcherImpl() {
|
| + CHECK(task_runner_->BelongsToCurrentThread());
|
| +
|
| + // Close all idle streams immediately. The |close_timer_| will handle
|
| + // invalidating any outstanding tasks upon its destruction.
|
| + CloseAllIdleStreams();
|
| +
|
| // There must be no idle proxy streams.
|
| CHECK_EQ(idle_proxies_, 0u);
|
|
|
| @@ -122,24 +128,6 @@ void AudioOutputDispatcherImpl::CloseStream(AudioOutputProxy* stream_proxy) {
|
| close_timer_.Reset();
|
| }
|
|
|
| -void AudioOutputDispatcherImpl::Shutdown() {
|
| - DCHECK(task_runner_->BelongsToCurrentThread());
|
| -
|
| - // Close all idle streams immediately. The |close_timer_| will handle
|
| - // invalidating any outstanding tasks upon its destruction.
|
| - CloseAllIdleStreams();
|
| -
|
| - // No AudioOutputProxy objects should hold a reference to us when we get
|
| - // to this stage.
|
| - DCHECK(HasOneRef()) << "Only the AudioManager should hold a reference";
|
| -
|
| - LOG_IF(WARNING, idle_proxies_ > 0u) << "Idle proxy streams during shutdown: "
|
| - << idle_proxies_;
|
| - LOG_IF(WARNING, !proxy_to_physical_map_.empty())
|
| - << "Active proxy streams during shutdown: "
|
| - << proxy_to_physical_map_.size();
|
| -}
|
| -
|
| bool AudioOutputDispatcherImpl::HasOutputProxies() const {
|
| return idle_proxies_ || !proxy_to_physical_map_.empty();
|
| }
|
|
|