Commit a32dbf2a authored by Andreas Cadhalpun's avatar Andreas Cadhalpun Committed by Luca Barbato

asfdec: break if EOF is reached after asf_read_packet_header

asf_read_payload can unset eof_reached, so check it also before calling
that function.

This fixes infinite loops.
Signed-off-by: 's avatarAndreas Cadhalpun <Andreas.Cadhalpun@googlemail.com>
Signed-off-by: 's avatarAlexandra Hájková <alexandra@khirnov.net>
Signed-off-by: 's avatarLuca Barbato <lu_zero@gentoo.org>
parent 389b7984
......@@ -1425,6 +1425,8 @@ static int asf_read_packet(AVFormatContext *s, AVPacket *pkt)
while (!pb->eof_reached) {
if (asf->state == PARSE_PACKET_HEADER) {
asf_read_packet_header(s);
if (pb->eof_reached)
break;
if (!asf->nb_mult_left)
asf->state = READ_SINGLE;
else
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment