mirror of
https://git.ffmpeg.org/ffmpeg.git
synced 2025-02-03 13:24:05 +00:00
avformat/flic: fix handling of EOF case
Signed-off-by: Paul B Mahol <onemda@gmail.com>
This commit is contained in:
parent
5781c983d8
commit
25d9cb4621
@ -204,7 +204,7 @@ static int flic_read_packet(AVFormatContext *s,
|
||||
int ret = 0;
|
||||
unsigned char preamble[FLIC_PREAMBLE_SIZE];
|
||||
|
||||
while (!packet_read) {
|
||||
while (!packet_read && !avio_feof(pb)) {
|
||||
|
||||
if ((ret = avio_read(pb, preamble, FLIC_PREAMBLE_SIZE)) !=
|
||||
FLIC_PREAMBLE_SIZE) {
|
||||
@ -256,7 +256,7 @@ static int flic_read_packet(AVFormatContext *s,
|
||||
}
|
||||
}
|
||||
|
||||
return ret;
|
||||
return avio_feof(pb) ? AVERROR_EOF : ret;
|
||||
}
|
||||
|
||||
AVInputFormat ff_flic_demuxer = {
|
||||
|
Loading…
Reference in New Issue
Block a user