[FFmpeg-cvslog] vf_format: check input validity
Vittorio Giovara
git at videolan.org
Sun Jan 18 01:09:33 CET 2015
ffmpeg | branch: release/2.4 | Vittorio Giovara <vittorio.giovara at gmail.com> | Sat Oct 18 16:10:35 2014 +0100| [d1ad85fc020653be5ad25ed1d3d5091e89fee782] | committer: Vittorio Giovara
vf_format: check input validity
CC: libav-stable at libav.org
> http://git.videolan.org/gitweb.cgi/ffmpeg.git/?a=commit;h=d1ad85fc020653be5ad25ed1d3d5091e89fee782
---
libavfilter/vf_format.c | 5 +++++
1 file changed, 5 insertions(+)
diff --git a/libavfilter/vf_format.c b/libavfilter/vf_format.c
index d37f870..914089d 100644
--- a/libavfilter/vf_format.c
+++ b/libavfilter/vf_format.c
@@ -59,6 +59,11 @@ static av_cold int init(AVFilterContext *ctx)
int nb_formats = 1;
int i;
+ if (!s->pix_fmts) {
+ av_log(ctx, AV_LOG_ERROR, "Empty output format string.\n");
+ return AVERROR(EINVAL);
+ }
+
/* count the formats */
cur = s->pix_fmts;
while ((cur = strchr(cur, '|'))) {
More information about the ffmpeg-cvslog
mailing list