|
|
@@ -384,10 +384,14 @@ static int read_packet(AVFormatContext *avctx, AVPacket *pkt) |
|
|
{ |
|
|
{ |
|
|
MlvContext *mlv = avctx->priv_data; |
|
|
MlvContext *mlv = avctx->priv_data; |
|
|
AVIOContext *pb; |
|
|
AVIOContext *pb; |
|
|
AVStream *st = avctx->streams[mlv->stream_index]; |
|
|
|
|
|
|
|
|
AVStream *st; |
|
|
int index, ret; |
|
|
int index, ret; |
|
|
unsigned int size, space; |
|
|
unsigned int size, space; |
|
|
|
|
|
|
|
|
|
|
|
if (!avctx->nb_streams) |
|
|
|
|
|
return AVERROR_EOF; |
|
|
|
|
|
|
|
|
|
|
|
st = avctx->streams[mlv->stream_index]; |
|
|
if (mlv->pts >= st->duration) |
|
|
if (mlv->pts >= st->duration) |
|
|
return AVERROR_EOF; |
|
|
return AVERROR_EOF; |
|
|
|
|
|
|
|
|
|