libavcodec/wmv2.c:70: error: Buffer Overrun L1
  Offset: [61, 64] (⇐ [5, 8] + 56) Size: 6 by call to `wmv2_add_block`.

libavcodec/wmv2.c:70:5: Call
68. 
69.     wmv2_add_block(w, block1[4], dest_cb                   , s->uvlinesize, 4);
70.     wmv2_add_block(w, block1[5], dest_cr                   , s->uvlinesize, 5);
        ^
71. }
72. 

libavcodec/wmv2.c:35:1: Parameter `n`
  33. }
  34. 
  35. static void wmv2_add_block(Wmv2Context *w, DCTELEM *block1, uint8_t *dst, int stride, int n){
      ^
  36.     MpegEncContext * const s= &w->s;
  37. 

libavcodec/wmv2.c:50:9: Call
  48.     case 2:
  49.         ff_simple_idct48_add(dst           , stride, block1);
  50.         ff_simple_idct48_add(dst + 4       , stride, w->abt_block2[n]);
              ^
  51.         s->dsp.clear_block(w->abt_block2[n]);
  52.         break;

libavcodec/simple_idct.c:195:1: Parameter `*block`
    193. }
    194. 
    195. void ff_simple_idct48_add(uint8_t *dest, int line_size, DCTELEM *block)
         ^
    196. {
    197.     int i;

libavcodec/simple_idct.c:206:9: Call
    204.     /* IDCT8 and store */
    205.     for(i=0; i<4; i++){
    206.         idctSparseColAdd_8(dest + i, line_size, block + i);
                 ^
    207.     }
    208. }

libavcodec/simple_idct_template.c:236:1: <Length trace>
234. }
235. 
236. static inline void FUNC(idctSparseColAdd)(pixel *dest, int line_size,
     ^
237.                                           DCTELEM *col)
238. {

libavcodec/simple_idct_template.c:236:1: Parameter `*col`
      234. }
      235. 
      236. static inline void FUNC(idctSparseColAdd)(pixel *dest, int line_size,
           ^
      237.                                           DCTELEM *col)
      238. {

libavcodec/simple_idct_template.c:284:13: Array access: Offset: [61, 64] (⇐ [5, 8] + 56) Size: 6 by call to `wmv2_add_block` 
      282.         }
      283. 
      284.         if (col[8*7]) {
                       ^
      285.             MAC(b0, + W7, col[8*7]);
      286.             MAC(b1, - W5, col[8*7]);

static inline void FUNC(idctSparseColAdd)(pixel *dest, int line_size,
                                          DCTELEM *col)
{
        int a0, a1, a2, a3, b0, b1, b2, b3;
        INIT_CLIP;
        a0 = W4 * (col[8*0] + ((1<<(COL_SHIFT-1))/W4));
        a1 = a0;
        a2 = a0;
        a3 = a0;
        a0 +=  + W2*col[8*2];
        a1 +=  + W6*col[8*2];
        a2 +=  - W6*col[8*2];
        a3 +=  - W2*col[8*2];
        b0 = MUL(W1, col[8*1]);
        b1 = MUL(W3, col[8*1]);
        b2 = MUL(W5, col[8*1]);
        b3 = MUL(W7, col[8*1]);
        MAC(b0, + W3, col[8*3]);
        MAC(b1, - W7, col[8*3]);
        MAC(b2, - W1, col[8*3]);
        MAC(b3, - W5, col[8*3]);
        if(col[8*4]){
            a0 += + W4*col[8*4];
            a1 += - W4*col[8*4];
            a2 += - W4*col[8*4];
            a3 += + W4*col[8*4];
        }
        if (col[8*5]) {
            MAC(b0, + W5, col[8*5]);
            MAC(b1, - W1, col[8*5]);
            MAC(b2, + W7, col[8*5]);
            MAC(b3, + W3, col[8*5]);
        }
        if(col[8*6]){
            a0 += + W6*col[8*6];
            a1 += - W2*col[8*6];
            a2 += + W2*col[8*6];
            a3 += - W6*col[8*6];
        }
        if (col[8*7]) {
            MAC(b0, + W7, col[8*7]);
            MAC(b1, - W5, col[8*7]);
            MAC(b2, + W3, col[8*7]);
            MAC(b3, - W1, col[8*7]);
        }
        dest[0] = CLIP(dest[0] + ((a0 + b0) >> COL_SHIFT));
        dest += line_size;
        dest[0] = CLIP(dest[0] + ((a1 + b1) >> COL_SHIFT));
        dest += line_size;
        dest[0] = CLIP(dest[0] + ((a2 + b2) >> COL_SHIFT));
        dest += line_size;
        dest[0] = CLIP(dest[0] + ((a3 + b3) >> COL_SHIFT));
        dest += line_size;
        dest[0] = CLIP(dest[0] + ((a3 - b3) >> COL_SHIFT));
        dest += line_size;
        dest[0] = CLIP(dest[0] + ((a2 - b2) >> COL_SHIFT));
        dest += line_size;
        dest[0] = CLIP(dest[0] + ((a1 - b1) >> COL_SHIFT));
        dest += line_size;
        dest[0] = CLIP(dest[0] + ((a0 - b0) >> COL_SHIFT));
}
['void ff_wmv2_add_mb(MpegEncContext *s, DCTELEM block1[6][64], uint8_t *dest_y, uint8_t *dest_cb, uint8_t *dest_cr){\n    Wmv2Context * const w= (Wmv2Context*)s;\n    wmv2_add_block(w, block1[0], dest_y                    , s->linesize, 0);\n    wmv2_add_block(w, block1[1], dest_y + 8                , s->linesize, 1);\n    wmv2_add_block(w, block1[2], dest_y +     8*s->linesize, s->linesize, 2);\n    wmv2_add_block(w, block1[3], dest_y + 8 + 8*s->linesize, s->linesize, 3);\n    if(s->flags&CODEC_FLAG_GRAY) return;\n    wmv2_add_block(w, block1[4], dest_cb                   , s->uvlinesize, 4);\n    wmv2_add_block(w, block1[5], dest_cr                   , s->uvlinesize, 5);\n}', 'static void wmv2_add_block(Wmv2Context *w, DCTELEM *block1, uint8_t *dst, int stride, int n){\n    MpegEncContext * const s= &w->s;\n  if (s->block_last_index[n] >= 0) {\n    switch(w->abt_type_table[n]){\n    case 0:\n        s->dsp.idct_add (dst, stride, block1);\n        break;\n    case 1:\n        ff_simple_idct84_add(dst           , stride, block1);\n        ff_simple_idct84_add(dst + 4*stride, stride, w->abt_block2[n]);\n        s->dsp.clear_block(w->abt_block2[n]);\n        break;\n    case 2:\n        ff_simple_idct48_add(dst           , stride, block1);\n        ff_simple_idct48_add(dst + 4       , stride, w->abt_block2[n]);\n        s->dsp.clear_block(w->abt_block2[n]);\n        break;\n    default:\n        av_log(s->avctx, AV_LOG_ERROR, "internal error in WMV2 abt\\n");\n    }\n  }\n}', 'void ff_simple_idct48_add(uint8_t *dest, int line_size, DCTELEM *block)\n{\n    int i;\n    for(i=0; i<8; i++) {\n        idct4row(block + i*8);\n    }\n    for(i=0; i<4; i++){\n        idctSparseColAdd_8(dest + i, line_size, block + i);\n    }\n}', 'static inline void FUNC(idctSparseColAdd)(pixel *dest, int line_size,\n                                          DCTELEM *col)\n{\n        int a0, a1, a2, a3, b0, b1, b2, b3;\n        INIT_CLIP;\n        a0 = W4 * (col[8*0] + ((1<<(COL_SHIFT-1))/W4));\n        a1 = a0;\n        a2 = a0;\n        a3 = a0;\n        a0 +=  + W2*col[8*2];\n        a1 +=  + W6*col[8*2];\n        a2 +=  - W6*col[8*2];\n        a3 +=  - W2*col[8*2];\n        b0 = MUL(W1, col[8*1]);\n        b1 = MUL(W3, col[8*1]);\n        b2 = MUL(W5, col[8*1]);\n        b3 = MUL(W7, col[8*1]);\n        MAC(b0, + W3, col[8*3]);\n        MAC(b1, - W7, col[8*3]);\n        MAC(b2, - W1, col[8*3]);\n        MAC(b3, - W5, col[8*3]);\n        if(col[8*4]){\n            a0 += + W4*col[8*4];\n            a1 += - W4*col[8*4];\n            a2 += - W4*col[8*4];\n            a3 += + W4*col[8*4];\n        }\n        if (col[8*5]) {\n            MAC(b0, + W5, col[8*5]);\n            MAC(b1, - W1, col[8*5]);\n            MAC(b2, + W7, col[8*5]);\n            MAC(b3, + W3, col[8*5]);\n        }\n        if(col[8*6]){\n            a0 += + W6*col[8*6];\n            a1 += - W2*col[8*6];\n            a2 += + W2*col[8*6];\n            a3 += - W6*col[8*6];\n        }\n        if (col[8*7]) {\n            MAC(b0, + W7, col[8*7]);\n            MAC(b1, - W5, col[8*7]);\n            MAC(b2, + W3, col[8*7]);\n            MAC(b3, - W1, col[8*7]);\n        }\n        dest[0] = CLIP(dest[0] + ((a0 + b0) >> COL_SHIFT));\n        dest += line_size;\n        dest[0] = CLIP(dest[0] + ((a1 + b1) >> COL_SHIFT));\n        dest += line_size;\n        dest[0] = CLIP(dest[0] + ((a2 + b2) >> COL_SHIFT));\n        dest += line_size;\n        dest[0] = CLIP(dest[0] + ((a3 + b3) >> COL_SHIFT));\n        dest += line_size;\n        dest[0] = CLIP(dest[0] + ((a3 - b3) >> COL_SHIFT));\n        dest += line_size;\n        dest[0] = CLIP(dest[0] + ((a2 - b2) >> COL_SHIFT));\n        dest += line_size;\n        dest[0] = CLIP(dest[0] + ((a1 - b1) >> COL_SHIFT));\n        dest += line_size;\n        dest[0] = CLIP(dest[0] + ((a0 - b0) >> COL_SHIFT));\n}']