]> git.sesse.net Git - ffmpeg/blobdiff - libavfilter/vf_fieldmatch.c
avfilter/vf_scale: store the offset in a local variable before adding it
[ffmpeg] / libavfilter / vf_fieldmatch.c
index 57ecf738641f69bf9f2f6c2b59097d31d02221a1..9626737b4008ecbaefdcd6f7a7e19b66ef8334e1 100644 (file)
@@ -951,8 +951,8 @@ static int config_input(AVFilterLink *inlink)
     fm->tpitchuv = FFALIGN(w >> 1, 16);
 
     fm->tbuffer = av_calloc((h/2 + 4) * fm->tpitchy, sizeof(*fm->tbuffer));
-    fm->c_array = av_malloc((((w + fm->blockx/2)/fm->blockx)+1) *
-                            (((h + fm->blocky/2)/fm->blocky)+1) *
+    fm->c_array = av_malloc_array((((w + fm->blockx/2)/fm->blockx)+1) *
+                            (((h + fm->blocky/2)/fm->blocky)+1),
                             4 * sizeof(*fm->c_array));
     if (!fm->tbuffer || !fm->c_array)
         return AVERROR(ENOMEM);
@@ -1040,7 +1040,7 @@ static const AVFilterPad fieldmatch_outputs[] = {
     { NULL }
 };
 
-AVFilter ff_vf_fieldmatch = {
+const AVFilter ff_vf_fieldmatch = {
     .name           = "fieldmatch",
     .description    = NULL_IF_CONFIG_SMALL("Field matching for inverse telecine."),
     .query_formats  = query_formats,