diff mbox series

[FFmpeg-devel,09/60] lavfi/vf_vmafmotion: fix variable shadowing

Message ID D41CE2FHVOO8.34A17APUOHQ06@gmail.com
State Accepted
Headers show
Series [FFmpeg-devel,01/60] fftools/ffmpeg_opt: fix variable shadowing | expand

Checks

Context Check Description
yinshiyou/make_loongarch64 success Make finished
yinshiyou/make_fate_loongarch64 success Make fate finished
andriy/make_x86 success Make finished
andriy/make_fate_x86 success Make fate finished

Commit Message

Marvin Scholz Sept. 8, 2024, 6:05 p.m. UTC
---
 libavfilter/vf_vmafmotion.c | 5 ++---
 1 file changed, 2 insertions(+), 3 deletions(-)

Comments

Anton Khirnov Sept. 9, 2024, 10:16 a.m. UTC | #1
Quoting Marvin Scholz (2024-09-08 20:05:57)
> ---
>  libavfilter/vf_vmafmotion.c | 5 ++---
>  1 file changed, 2 insertions(+), 3 deletions(-)

Likely ok
diff mbox series

Patch

diff --git a/libavfilter/vf_vmafmotion.c b/libavfilter/vf_vmafmotion.c
index f9315e56b6..a8adc67019 100644
--- a/libavfilter/vf_vmafmotion.c
+++ b/libavfilter/vf_vmafmotion.c
@@ -90,11 +90,10 @@  static void convolution_x(const uint16_t *filter, int filt_w, const uint16_t *sr
     int borders_left = radius;
     int borders_right = w - (filt_w - radius);
     int i, j, k;
-    int sum = 0;
 
     for (i = 0; i < h; i++) {
         for (j = 0; j < borders_left; j++) {
-            sum = 0;
+            int sum = 0;
             for (k = 0; k < filt_w; k++) {
                 int j_tap = FFABS(j - radius + k);
                 if (j_tap >= w) {
@@ -114,7 +113,7 @@  static void convolution_x(const uint16_t *filter, int filt_w, const uint16_t *sr
         }
 
         for (j = borders_right; j < w; j++) {
-            sum = 0;
+            int sum = 0;
             for (k = 0; k < filt_w; k++) {
                 int j_tap = FFABS(j - radius + k);
                 if (j_tap >= w) {