]> git.sesse.net Git - ffmpeg/blobdiff - libavcodec/error_resilience.c
Merge commit '87a3ea3192bf5e4aafa08bca8686a2b577eae818'
[ffmpeg] / libavcodec / error_resilience.c
index 5410dc1cea2dfa37de5a0314cc217f82667aa4da..670e592b8c53f8863385eae8e9372f632ed92dcb 100644 (file)
@@ -136,8 +136,8 @@ static void guess_dc(ERContext *s, int16_t *dc, int w,
                      int h, int stride, int is_luma)
 {
     int b_x, b_y;
-    int16_t  (*col )[4] = av_malloc(stride*h*sizeof( int16_t)*4);
-    uint32_t (*dist)[4] = av_malloc(stride*h*sizeof(uint32_t)*4);
+    int16_t  (*col )[4] = av_malloc_array(stride, h*sizeof( int16_t)*4);
+    uint32_t (*dist)[4] = av_malloc_array(stride, h*sizeof(uint32_t)*4);
 
     if(!col || !dist) {
         av_log(s->avctx, AV_LOG_ERROR, "guess_dc() is out of memory\n");