changeset 340:850f7b4f15ed libavformat

10l
author michael
date Sun, 04 Jan 2004 19:53:44 +0000
parents a07c42730632
children ad2a57c5467a
files avidec.c
diffstat 1 files changed, 4 insertions(+), 2 deletions(-) [+]
line wrap: on
line diff
--- a/avidec.c	Sat Jan 03 13:29:46 2004 +0000
+++ b/avidec.c	Sun Jan 04 19:53:44 2004 +0000
@@ -659,8 +659,10 @@
     for(i=0;i<s->nb_streams;i++) {
         AVStream *st = s->streams[i];
         AVIStream *ast = st->priv_data;
-        av_free(ast->index_entries);
-        av_free(ast);
+        if(ast){
+            av_free(ast->index_entries);
+            av_free(ast);
+        }
         av_free(st->codec.extradata);
         av_free(st->codec.palctrl);
     }