| Index: media/filters/source_buffer_stream.cc
|
| diff --git a/media/filters/source_buffer_stream.cc b/media/filters/source_buffer_stream.cc
|
| index 5507acc7c4b5134ef2c5b636432e2a4ed7a5364b..3f1b42d82662bc262607896ee3c1daa15e58e157 100644
|
| --- a/media/filters/source_buffer_stream.cc
|
| +++ b/media/filters/source_buffer_stream.cc
|
| @@ -557,7 +557,6 @@ int SourceBufferStream::FreeBuffers(int total_bytes_to_free,
|
| SourceBufferRange* new_range_for_append = NULL;
|
|
|
| while (!ranges_.empty() && bytes_to_free > 0) {
|
| -
|
| SourceBufferRange* current_range = NULL;
|
| BufferQueue buffers;
|
| int bytes_deleted = 0;
|
| @@ -1061,6 +1060,11 @@ bool SourceBufferStream::UpdateAudioConfig(const AudioDecoderConfig& config) {
|
| return false;
|
| }
|
|
|
| + if (audio_configs_[0]->is_encrypted() != config.is_encrypted()) {
|
| + MEDIA_LOG(log_cb_) << "Audio encryption changes not allowed.";
|
| + return false;
|
| + }
|
| +
|
| // Check to see if the new config matches an existing one.
|
| for (size_t i = 0; i < audio_configs_.size(); ++i) {
|
| if (config.Matches(*audio_configs_[i])) {
|
| @@ -1091,6 +1095,11 @@ bool SourceBufferStream::UpdateVideoConfig(const VideoDecoderConfig& config) {
|
| return false;
|
| }
|
|
|
| + if (video_configs_[0]->is_encrypted() != config.is_encrypted()) {
|
| + MEDIA_LOG(log_cb_) << "Video encryption changes not allowed.";
|
| + return false;
|
| + }
|
| +
|
| // Check to see if the new config matches an existing one.
|
| for (size_t i = 0; i < video_configs_.size(); ++i) {
|
| if (config.Matches(*video_configs_[i])) {
|
|
|