| Index: media/cast/cast_environment.cc
|
| diff --git a/media/cast/cast_environment.cc b/media/cast/cast_environment.cc
|
| index 93eb8c72522fa28e5963b407cf1a0cd86bfb5d32..f22f0a4eca220bf1041baa3467ec0192f8f6f75a 100644
|
| --- a/media/cast/cast_environment.cc
|
| +++ b/media/cast/cast_environment.cc
|
| @@ -34,7 +34,8 @@ CastEnvironment::CastEnvironment(
|
|
|
| CastEnvironment::~CastEnvironment() {
|
| // Logging must be deleted on the main thread.
|
| - if (main_thread_proxy_ && !main_thread_proxy_->RunsTasksOnCurrentThread()) {
|
| + if (main_thread_proxy_.get() &&
|
| + !main_thread_proxy_->RunsTasksOnCurrentThread()) {
|
| main_thread_proxy_->PostTask(
|
| FROM_HERE,
|
| base::Bind(&DeleteLoggingOnMainThread, base::Passed(&logging_)));
|
| @@ -73,13 +74,13 @@ scoped_refptr<SingleThreadTaskRunner> CastEnvironment::GetTaskRunner(
|
| bool CastEnvironment::CurrentlyOn(ThreadId identifier) {
|
| switch (identifier) {
|
| case CastEnvironment::MAIN:
|
| - return main_thread_proxy_ &&
|
| + return main_thread_proxy_.get() &&
|
| main_thread_proxy_->RunsTasksOnCurrentThread();
|
| case CastEnvironment::AUDIO:
|
| - return audio_thread_proxy_ &&
|
| + return audio_thread_proxy_.get() &&
|
| audio_thread_proxy_->RunsTasksOnCurrentThread();
|
| case CastEnvironment::VIDEO:
|
| - return video_thread_proxy_ &&
|
| + return video_thread_proxy_.get() &&
|
| video_thread_proxy_->RunsTasksOnCurrentThread();
|
| default:
|
| NOTREACHED() << "Invalid thread identifier";
|
|
|