1
0
mirror of https://github.com/FFmpeg/FFmpeg.git synced 2025-01-19 05:49:09 +02:00

add one missing check for stream existence in read_elst, fix #1364

backported patch r19792 by bcoudurier




Originally committed as revision 21709 to svn://svn.ffmpeg.org/ffmpeg/branches/0.5
This commit is contained in:
Reinhard Tartler 2010-02-09 18:41:17 +00:00
parent 95f90d27d2
commit e91ba7dc9d

View File

@ -1776,9 +1776,13 @@ free_and_return:
/* edit list atom */
static int mov_read_elst(MOVContext *c, ByteIOContext *pb, MOVAtom atom)
{
MOVStreamContext *sc = c->fc->streams[c->fc->nb_streams-1]->priv_data;
MOVStreamContext *sc;
int i, edit_count;
if (c->fc->nb_streams < 1)
return 0;
sc = c->fc->streams[c->fc->nb_streams-1]->priv_data;
get_byte(pb); /* version */
get_be24(pb); /* flags */
edit_count = get_be32(pb); /* entries */