return LAST_BUFFER_ERROR when last buffer reached
git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@30549 a95241bf-73f2-0310-859d-f6bbb57e9c96
This commit is contained in:
parent
008c3af957
commit
4d97ad948b
@ -467,8 +467,13 @@ avCodec::Decode(void *out_buffer, int64 *out_frameCount,
|
|||||||
media_header chunk_mh;
|
media_header chunk_mh;
|
||||||
status_t err;
|
status_t err;
|
||||||
err = GetNextChunk(&fChunkBuffer, &fChunkBufferSize, &chunk_mh);
|
err = GetNextChunk(&fChunkBuffer, &fChunkBufferSize, &chunk_mh);
|
||||||
|
if (err == B_LAST_BUFFER_ERROR) {
|
||||||
|
TRACE("Last Chunk with chunk size %ld\n",fChunkBufferSize);
|
||||||
|
fChunkBufferSize = 0;
|
||||||
|
return err;
|
||||||
|
}
|
||||||
if (err != B_OK || fChunkBufferSize < 0) {
|
if (err != B_OK || fChunkBufferSize < 0) {
|
||||||
TRACE("GetNextChunk error %ld\n",fChunkBufferSize);
|
printf("GetNextChunk error %ld\n",fChunkBufferSize);
|
||||||
fChunkBufferSize = 0;
|
fChunkBufferSize = 0;
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user