mirror of
https://github.com/FFmpeg/FFmpeg.git
synced 2025-03-28 12:32:17 +02:00
avformat/oggdec: Check for EOF after page header
Fixes: Infinite loop Fixes: Ticket8594 Signed-off-by: Michael Niedermayer <michael@niedermayer.cc> (cherry picked from commit f1589be9fda00c417f9bcccb55dbbea998ee08ac) Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
This commit is contained in:
parent
1ff19987be
commit
b4ac197257
@ -369,6 +369,9 @@ static int ogg_read_page(AVFormatContext *s, int *sid)
|
|||||||
avio_skip(bc, 8); /* seq, crc */
|
avio_skip(bc, 8); /* seq, crc */
|
||||||
nsegs = avio_r8(bc);
|
nsegs = avio_r8(bc);
|
||||||
|
|
||||||
|
if (avio_feof(bc))
|
||||||
|
return AVERROR_EOF;
|
||||||
|
|
||||||
idx = ogg_find_stream(ogg, serial);
|
idx = ogg_find_stream(ogg, serial);
|
||||||
if (idx < 0) {
|
if (idx < 0) {
|
||||||
if (data_packets_seen(ogg))
|
if (data_packets_seen(ogg))
|
||||||
|
Loading…
x
Reference in New Issue
Block a user