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

Unified Diff: chromecast/media/cma/decoder/cast_audio_decoder_linux.cc

Issue 2815303006: Convert MediaLog from being ref counted to owned by WebMediaPlayer. (Closed)
Patch Set: Fix cast, fuzzers. Created 3 years, 8 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
Index: chromecast/media/cma/decoder/cast_audio_decoder_linux.cc
diff --git a/chromecast/media/cma/decoder/cast_audio_decoder_linux.cc b/chromecast/media/cma/decoder/cast_audio_decoder_linux.cc
index 2ef1fa40c7b600f88e7f2b98ede5b6e108204bea..2201380975be233c5eccd94a92a94103b64281c1 100644
--- a/chromecast/media/cma/decoder/cast_audio_decoder_linux.cc
+++ b/chromecast/media/cma/decoder/cast_audio_decoder_linux.cc
@@ -68,8 +68,7 @@ class CastAudioDecoderImpl : public CastAudioDecoder {
::media::CHANNEL_LAYOUT_STEREO));
}
base::WeakPtr<CastAudioDecoderImpl> self = weak_factory_.GetWeakPtr();
- decoder_.reset(new ::media::FFmpegAudioDecoder(
- task_runner_, make_scoped_refptr(new ::media::MediaLog())));
+ decoder_.reset(new ::media::FFmpegAudioDecoder(task_runner_, &media_log_));
decoder_->Initialize(
media::DecoderConfigAdapter::ToMediaAudioDecoderConfig(config_),
nullptr, base::Bind(&CastAudioDecoderImpl::OnInitialized, self),
@@ -246,6 +245,7 @@ class CastAudioDecoderImpl : public CastAudioDecoder {
new media::DecoderBufferAdapter(config_.id, result));
}
+ ::media::MediaLog media_log_;
const scoped_refptr<base::SingleThreadTaskRunner> task_runner_;
InitializedCallback initialized_callback_;
OutputFormat output_format_;

Powered by Google App Engine
This is Rietveld 408576698