mirror of
https://github.com/nyanmisaka/ffmpeg-rockchip.git
synced 2026-01-23 23:21:06 +01:00
mmf: signal EOF
Signed-off-by: Paul B Mahol <onemda@gmail.com>
This commit is contained in:
parent
9378a90add
commit
7f321fca23
1 changed files with 2 additions and 5 deletions
|
|
@ -268,16 +268,13 @@ static int mmf_read_packet(AVFormatContext *s,
|
|||
MMFContext *mmf = s->priv_data;
|
||||
int ret, size;
|
||||
|
||||
if (url_feof(s->pb))
|
||||
return AVERROR(EIO);
|
||||
if (url_feof(s->pb) || !mmf->data_size)
|
||||
return AVERROR_EOF;
|
||||
|
||||
size = MAX_SIZE;
|
||||
if(size > mmf->data_size)
|
||||
size = mmf->data_size;
|
||||
|
||||
if(!size)
|
||||
return AVERROR(EIO);
|
||||
|
||||
ret = av_get_packet(s->pb, pkt, size);
|
||||
if (ret < 0)
|
||||
return ret;
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue