1
0
mirror of https://github.com/FFmpeg/FFmpeg.git synced 2024-12-23 12:43:46 +02:00

matroskadec: move setting of matroska->done inside matroska_parse_cluster()

Originally committed as revision 14955 to svn://svn.ffmpeg.org/ffmpeg/trunk
This commit is contained in:
Aurelien Jacobs 2008-08-24 23:54:14 +00:00
parent bde51e6a8a
commit 653fb2f80c

View File

@ -1618,6 +1618,7 @@ static int matroska_parse_cluster(MatroskaDemuxContext *matroska)
blocks[i].bin.pos, cluster.timecode,
blocks[i].duration, !blocks[i].reference);
ebml_free(matroska_cluster, &cluster);
if (res < 0) matroska->done = 1;
return res;
}
@ -1628,8 +1629,7 @@ static int matroska_read_packet(AVFormatContext *s, AVPacket *pkt)
while (matroska_deliver_packet(matroska, pkt)) {
if (matroska->done)
return AVERROR(EIO);
if (matroska_parse_cluster(matroska) < 0)
matroska->done = 1;
matroska_parse_cluster(matroska);
}
return 0;