diff options
author | Reimar Döffinger <Reimar.Doeffinger@gmx.de> | 2008-02-04 12:13:09 +0000 |
---|---|---|
committer | Reimar Döffinger <Reimar.Doeffinger@gmx.de> | 2008-02-04 12:13:09 +0000 |
commit | cd41a73f89708bcccf8c4d4b9857ea5ef529e1a1 (patch) | |
tree | 7acd2a25155e076d528cd56a2ca9f331e2a250cf | |
parent | 4ddcc983b40ce9904cc7136f3cb7af75299e1234 (diff) | |
download | ffmpeg-cd41a73f89708bcccf8c4d4b9857ea5ef529e1a1.tar.gz |
Fix a possible use of an uninitialized pointer.
Originally committed as revision 11857 to svn://svn.ffmpeg.org/ffmpeg/trunk
-rw-r--r-- | libavformat/sierravmd.c | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/libavformat/sierravmd.c b/libavformat/sierravmd.c index 0f5063471c..5e68a81c43 100644 --- a/libavformat/sierravmd.c +++ b/libavformat/sierravmd.c @@ -73,7 +73,7 @@ static int vmd_read_header(AVFormatContext *s, { VmdDemuxContext *vmd = s->priv_data; ByteIOContext *pb = s->pb; - AVStream *st, *vst; + AVStream *st = NULL, *vst; unsigned int toc_offset; unsigned char *raw_frame_table; int raw_frame_table_size; @@ -181,6 +181,7 @@ static int vmd_read_header(AVFormatContext *s, continue; switch(type) { case 1: /* Audio Chunk */ + if (!st) break; /* first audio chunk contains several audio buffers */ if(current_audio_pts){ vmd->frame_table[total_frames].frame_offset = current_offset; |