summaryrefslogtreecommitdiffstats
path: root/media
diff options
context:
space:
mode:
authorAndreas Huber <andih@google.com>2011-04-01 14:01:09 -0700
committerAndroid (Google) Code Review <android-gerrit@google.com>2011-04-01 14:01:09 -0700
commit5e9c3de539ea255d9aaa1c141650005a37b1a3a3 (patch)
treec0191e4e71cda7ec89a057a358b301611bbdb565 /media
parent09bc5f5b5789818bee8d6eae3df68d855c627326 (diff)
parent21796929d37a290f069faad4bd04b356c5579296 (diff)
downloadframeworks_base-5e9c3de539ea255d9aaa1c141650005a37b1a3a3.zip
frameworks_base-5e9c3de539ea255d9aaa1c141650005a37b1a3a3.tar.gz
frameworks_base-5e9c3de539ea255d9aaa1c141650005a37b1a3a3.tar.bz2
Merge "Fix a webm-seek issue introduced when adding support for streaming webm"
Diffstat (limited to 'media')
-rw-r--r--media/libstagefright/matroska/MatroskaExtractor.cpp5
1 files changed, 4 insertions, 1 deletions
diff --git a/media/libstagefright/matroska/MatroskaExtractor.cpp b/media/libstagefright/matroska/MatroskaExtractor.cpp
index b3e29b9..64266b8 100644
--- a/media/libstagefright/matroska/MatroskaExtractor.cpp
+++ b/media/libstagefright/matroska/MatroskaExtractor.cpp
@@ -291,6 +291,7 @@ void BlockIterator::reset() {
Mutex::Autolock autoLock(mExtractor->mLock);
mCluster = mExtractor->mSegment->GetFirst();
+ mBlockEntry = NULL;
mBlockEntryIndex = 0;
do {
@@ -302,11 +303,13 @@ void BlockIterator::seek(int64_t seekTimeUs) {
Mutex::Autolock autoLock(mExtractor->mLock);
mCluster = mExtractor->mSegment->FindCluster(seekTimeUs * 1000ll);
+ mBlockEntry = NULL;
mBlockEntryIndex = 0;
- while (!eos() && block()->GetTrackNumber() != mTrackNum) {
+ do {
advance_l();
}
+ while (!eos() && block()->GetTrackNumber() != mTrackNum);
while (!eos() && !mBlockEntry->GetBlock()->IsKey()) {
advance_l();