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

Unified Diff: media/filters/source_buffer_stream.cc

Issue 11785029: Prevent SourceBufferRange.waiting_for_keyframe_ from being lost on range merges. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 7 years, 11 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
« no previous file with comments | « no previous file | media/filters/source_buffer_stream_unittest.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: media/filters/source_buffer_stream.cc
diff --git a/media/filters/source_buffer_stream.cc b/media/filters/source_buffer_stream.cc
index 3f1b42d82662bc262607896ee3c1daa15e58e157..f50a397aa0be608704a910b536414967af589ab6 100644
--- a/media/filters/source_buffer_stream.cc
+++ b/media/filters/source_buffer_stream.cc
@@ -1498,8 +1498,13 @@ void SourceBufferRange::AppendRangeToEnd(const SourceBufferRange& range,
DCHECK(CanAppendRangeToEnd(range));
DCHECK(!buffers_.empty());
- if (transfer_current_position)
- next_buffer_index_ = range.next_buffer_index_ + buffers_.size();
+ if (transfer_current_position) {
+ if (range.next_buffer_index_ >= 0)
scherkus (not reviewing) 2013/01/07 23:34:06 aside from not updating w_f_k_/n_k_t_, was there a
acolwell GONE FROM CHROMIUM 2013/01/08 00:46:39 The test exposes both problems. When waiting_for_k
+ next_buffer_index_ = range.next_buffer_index_ + buffers_.size();
+
+ waiting_for_keyframe_ = range.waiting_for_keyframe_;
+ next_keyframe_timestamp_ = range.next_keyframe_timestamp_;
+ }
AppendBuffersToEnd(range.buffers_);
}
« no previous file with comments | « no previous file | media/filters/source_buffer_stream_unittest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698