[Ffmpeg-cvslog] r7225 - trunk/ffmpeg.c

bcoudurier subversion
Tue Dec 5 15:01:44 CET 2006


Author: bcoudurier
Date: Tue Dec  5 15:01:44 2006
New Revision: 7225

Modified:
   trunk/ffmpeg.c

Log:
fix memleak, free stream codec allocated by av_new_stream

Modified: trunk/ffmpeg.c
==============================================================================
--- trunk/ffmpeg.c	(original)
+++ trunk/ffmpeg.c	Tue Dec  5 15:01:44 2006
@@ -3942,8 +3942,10 @@
         int j;
         if (!(s->oformat->flags & AVFMT_NOFILE))
             url_fclose(&s->pb);
-        for(j=0;j<s->nb_streams;j++)
+        for(j=0;j<s->nb_streams;j++) {
+            av_free(s->streams[j]->codec);
             av_free(s->streams[j]);
+        }
         av_free(s);
     }
     for(i=0;i<nb_input_files;i++)




More information about the ffmpeg-cvslog mailing list