ffmpeg | branch: master | Michael Niedermayer <michae...@gmx.at> | Fri Nov 21 22:15:32 2014 +0100| [b9ffafbfcc0f8aaffc9de3919a1d295dbe6d53f7] | committer: Michael Niedermayer
avfilter/formats: Alloc NULL fmts in SET_COMMON_FORMATS() This avoids null pointer dereferences in case memory allocation has failed Signed-off-by: Michael Niedermayer <michae...@gmx.at> > http://git.videolan.org/gitweb.cgi/ffmpeg.git/?a=commit;h=b9ffafbfcc0f8aaffc9de3919a1d295dbe6d53f7 --- libavfilter/formats.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/libavfilter/formats.c b/libavfilter/formats.c index 42afcf4..eb3b87a 100644 --- a/libavfilter/formats.c +++ b/libavfilter/formats.c @@ -494,7 +494,7 @@ void ff_formats_changeref(AVFilterFormats **oldref, AVFilterFormats **newref) } #define SET_COMMON_FORMATS(ctx, fmts, in_fmts, out_fmts, ref, list) \ -{ \ +if (fmts) { \ int count = 0, i; \ \ for (i = 0; i < ctx->nb_inputs; i++) { \ _______________________________________________ ffmpeg-cvslog mailing list ffmpeg-cvslog@ffmpeg.org http://ffmpeg.org/mailman/listinfo/ffmpeg-cvslog