# HG changeset patch # User reimar # Date 1202127189 0 # Node ID a086b58a3336272abb1807309ed8dd97e7c409cc # Parent eac2648449a5b7675c5d480d3d26bd7eb9a1ab8e Fix a possible use of an uninitialized pointer. diff -r eac2648449a5 -r a086b58a3336 sierravmd.c --- a/sierravmd.c Mon Feb 04 10:48:41 2008 +0000 +++ b/sierravmd.c Mon Feb 04 12:13:09 2008 +0000 @@ -73,7 +73,7 @@ { 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 @@ 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;