diff options
author | Andreas Huber <andih@google.com> | 2010-01-25 10:41:35 -0800 |
---|---|---|
committer | Andreas Huber <andih@google.com> | 2010-01-25 11:24:26 -0800 |
commit | 213addfaf4b359c69da4e9b4490c511d116845bb (patch) | |
tree | a3a46a11cbb8b3a7ed2961a125ce712e52f0e490 /media/libstagefright/SampleIterator.cpp | |
parent | a826028dc33a83538a2ac6bd13ca46a52de7a9be (diff) | |
download | frameworks_av-213addfaf4b359c69da4e9b4490c511d116845bb.zip frameworks_av-213addfaf4b359c69da4e9b4490c511d116845bb.tar.gz frameworks_av-213addfaf4b359c69da4e9b4490c511d116845bb.tar.bz2 |
The qcom OMX video decoders do not allocate output buffer memory at the time OMX_AllocateBuffer is called, wait until we received the first FILL_BUFFER_DONE notification until we rely on the buffer data ptr.
Diffstat (limited to 'media/libstagefright/SampleIterator.cpp')
-rw-r--r-- | media/libstagefright/SampleIterator.cpp | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/media/libstagefright/SampleIterator.cpp b/media/libstagefright/SampleIterator.cpp index faad42b..7155c61 100644 --- a/media/libstagefright/SampleIterator.cpp +++ b/media/libstagefright/SampleIterator.cpp @@ -54,6 +54,10 @@ void SampleIterator::reset() { status_t SampleIterator::seekTo(uint32_t sampleIndex) { LOGV("seekTo(%d)", sampleIndex); + if (sampleIndex >= mTable->mNumSampleSizes) { + return ERROR_END_OF_STREAM; + } + if (mTable->mSampleToChunkOffset < 0 || mTable->mChunkOffsetOffset < 0 || mTable->mSampleSizeOffset < 0 |