]> git.sesse.net Git - ffmpeg/commitdiff
vc2enc: correctly zero out coefficient array padding
authorRostislav Pehlivanov <atomnuker@gmail.com>
Fri, 26 Feb 2016 12:21:36 +0000 (12:21 +0000)
committerRostislav Pehlivanov <atomnuker@gmail.com>
Fri, 26 Feb 2016 12:21:36 +0000 (12:21 +0000)
Credit for figuring this out goes to James Darnley.

Signed-off-by: Rostislav Pehlivanov <atomnuker@gmail.com>
libavcodec/vc2enc.c

index 71f74b50bce83b80942d9c022f960965b9c66372..3f030619cf77d8bf4bb773a0cf15fa5961ff2b54 100644 (file)
@@ -867,7 +867,7 @@ static int dwt_plane(AVCodecContext *avctx, void *arg)
         }
     }
 
-    memset(buf, 0, (p->coef_stride*p->dwt_height - p->height*p->width)*sizeof(dwtcoef));
+    memset(buf, 0, p->coef_stride * (p->dwt_height - p->height) * sizeof(dwtcoef));
 
     for (level = s->wavelet_depth-1; level >= 0; level--) {
         const SubBand *b = &p->band[level][0];