libavcodec/imgresample.c:391: error: Buffer Overrun L2
  Offset: [3, 63] (⇐ [0, 60] + 3) Size: 4 by call to `h_resample`.

libavcodec/imgresample.c:362:1: Parameter `s->h_filters[*][*]`
360. }
361. 
362. static void component_resample(ImgReSampleContext *s,
     ^
363.                                uint8_t *output, int owrap, int owidth, int oheight,
364.                                uint8_t *input, int iwrap, int iwidth, int iheight)

libavcodec/imgresample.c:391:13: Call
389.             new_line = s->line_buf + ring_y * owidth;
390.             /* apply filter and handle limit cases correctly */
391.             h_resample(new_line, owidth,
                 ^
392.                        src_line, iwidth, - FCENTER * POS_FRAC, s->h_incr,
393.                        &s->h_filters[0][0]);

libavcodec/imgresample.c:325:1: Parameter `*filters`
  323. }
  324. 
  325. static void h_resample(uint8_t *dst, int dst_width, const uint8_t *src,
       ^
  326.                        int src_width, int src_start, int src_incr,
  327.                        int16_t *filters)

libavcodec/imgresample.c:351:9: Call
  349.     else
  350. #endif
  351.         h_resample_fast(dst, n,
               ^
  352.                         src, src_width, src_start, src_incr, filters);
  353.     if (n < dst_width) {

libavcodec/imgresample.c:75:1: <Length trace>
73. 
74. /* This function must be optimized */
75. static void h_resample_fast(uint8_t *dst, int dst_width, const uint8_t *src,
    ^
76.                             int src_width, int src_start, int src_incr,
77.                             int16_t *filters)

libavcodec/imgresample.c:75:1: Parameter `*filters`
    73. 
    74. /* This function must be optimized */
    75. static void h_resample_fast(uint8_t *dst, int dst_width, const uint8_t *src,
        ^
    76.                             int src_width, int src_start, int src_incr,
    77.                             int16_t *filters)

libavcodec/imgresample.c:93:9: Assignment
    91.         s = src + (src_pos >> POS_FRAC_BITS);
    92.         phase = get_phase(src_pos);
    93.         filter = filters + phase * NB_TAPS;
                ^
    94. #if NB_TAPS == 4
    95.         sum = s[0] * filter[0] +

libavcodec/imgresample.c:98:20: Array access: Offset: [3, 63] (⇐ [0, 60] + 3) Size: 4 by call to `h_resample` 
     96.             s[1] * filter[1] +
     97.             s[2] * filter[2] +
     98.             s[3] * filter[3];
                            ^
     99. #else
    100.         {

static void h_resample_fast(uint8_t *dst, int dst_width, const uint8_t *src,
                            int src_width, int src_start, int src_incr,
                            int16_t *filters)
{
    int src_pos, phase, sum, i;
    const uint8_t *s;
    int16_t *filter;
    src_pos = src_start;
    for(i=0;i<dst_width;i++) {
#ifdef TEST
        if ((src_pos >> POS_FRAC_BITS) < 0 ||
            (src_pos >> POS_FRAC_BITS) > (src_width - NB_TAPS))
            av_abort();
#endif
        s = src + (src_pos >> POS_FRAC_BITS);
        phase = get_phase(src_pos);
        filter = filters + phase * NB_TAPS;
#if NB_TAPS == 4
        sum = s[0] * filter[0] +
            s[1] * filter[1] +
            s[2] * filter[2] +
            s[3] * filter[3];
#else
        {
            int j;
            sum = 0;
            for(j=0;j<NB_TAPS;j++)
                sum += s[j] * filter[j];
        }
#endif
        sum = sum >> FILTER_BITS;
        if (sum < 0)
            sum = 0;
        else if (sum > 255)
            sum = 255;
        dst[0] = sum;
        src_pos += src_incr;
        dst++;
    }
}
['static void component_resample(ImgReSampleContext *s,\n                               uint8_t *output, int owrap, int owidth, int oheight,\n                               uint8_t *input, int iwrap, int iwidth, int iheight)\n{\n    int src_y, src_y1, last_src_y, ring_y, phase_y, y1, y;\n    uint8_t *new_line, *src_line;\n    last_src_y = - FCENTER - 1;\n    src_y = (last_src_y + NB_TAPS) * POS_FRAC;\n    ring_y = NB_TAPS;\n    for(y=0;y<oheight;y++) {\n        src_y1 = src_y >> POS_FRAC_BITS;\n        while (last_src_y < src_y1) {\n            if (++ring_y >= LINE_BUF_HEIGHT + NB_TAPS)\n                ring_y = NB_TAPS;\n            last_src_y++;\n            y1 = last_src_y;\n            if (y1 < 0) {\n                y1 = 0;\n            } else if (y1 >= iheight) {\n                y1 = iheight - 1;\n            }\n            src_line = input + y1 * iwrap;\n            new_line = s->line_buf + ring_y * owidth;\n            h_resample(new_line, owidth,\n                       src_line, iwidth, - FCENTER * POS_FRAC, s->h_incr,\n                       &s->h_filters[0][0]);\n            if (ring_y >= LINE_BUF_HEIGHT) {\n                memcpy(s->line_buf + (ring_y - LINE_BUF_HEIGHT) * owidth,\n                       new_line, owidth);\n            }\n        }\n        phase_y = get_phase(src_y);\n#ifdef HAVE_MMX\n        if ((mm_flags & MM_MMX) && NB_TAPS == 4 && 0)\n            v_resample4_mmx(output, owidth,\n                            s->line_buf + (ring_y - NB_TAPS + 1) * owidth, owidth,\n                            &s->v_filters[phase_y][0]);\n        else\n#endif\n#ifdef HAVE_ALTIVEC\n            if ((mm_flags & MM_ALTIVEC) && NB_TAPS == 4 && FILTER_BITS <= 6)\n                v_resample16_altivec(output, owidth,\n                                s->line_buf + (ring_y - NB_TAPS + 1) * owidth, owidth,\n                                &s->v_filters[phase_y][0]);\n        else\n#endif\n            v_resample(output, owidth,\n                       s->line_buf + (ring_y - NB_TAPS + 1) * owidth, owidth,\n                       &s->v_filters[phase_y][0]);\n        src_y += s->v_incr;\n        output += owrap;\n    }\n}', 'static void h_resample(uint8_t *dst, int dst_width, const uint8_t *src,\n                       int src_width, int src_start, int src_incr,\n                       int16_t *filters)\n{\n    int n, src_end;\n    if (src_start < 0) {\n        n = (0 - src_start + src_incr - 1) / src_incr;\n        h_resample_slow(dst, n, src, src_width, src_start, src_incr, filters);\n        dst += n;\n        dst_width -= n;\n        src_start += n * src_incr;\n    }\n    src_end = src_start + dst_width * src_incr;\n    if (src_end > ((src_width - NB_TAPS) << POS_FRAC_BITS)) {\n        n = (((src_width - NB_TAPS + 1) << POS_FRAC_BITS) - 1 - src_start) /\n            src_incr;\n    } else {\n        n = dst_width;\n    }\n#ifdef HAVE_MMX\n    if ((mm_flags & MM_MMX) && NB_TAPS == 4)\n        h_resample_fast4_mmx(dst, n,\n                             src, src_width, src_start, src_incr, filters);\n    else\n#endif\n        h_resample_fast(dst, n,\n                        src, src_width, src_start, src_incr, filters);\n    if (n < dst_width) {\n        dst += n;\n        dst_width -= n;\n        src_start += n * src_incr;\n        h_resample_slow(dst, dst_width,\n                        src, src_width, src_start, src_incr, filters);\n    }\n}', 'static void h_resample_fast(uint8_t *dst, int dst_width, const uint8_t *src,\n                            int src_width, int src_start, int src_incr,\n                            int16_t *filters)\n{\n    int src_pos, phase, sum, i;\n    const uint8_t *s;\n    int16_t *filter;\n    src_pos = src_start;\n    for(i=0;i<dst_width;i++) {\n#ifdef TEST\n        if ((src_pos >> POS_FRAC_BITS) < 0 ||\n            (src_pos >> POS_FRAC_BITS) > (src_width - NB_TAPS))\n            av_abort();\n#endif\n        s = src + (src_pos >> POS_FRAC_BITS);\n        phase = get_phase(src_pos);\n        filter = filters + phase * NB_TAPS;\n#if NB_TAPS == 4\n        sum = s[0] * filter[0] +\n            s[1] * filter[1] +\n            s[2] * filter[2] +\n            s[3] * filter[3];\n#else\n        {\n            int j;\n            sum = 0;\n            for(j=0;j<NB_TAPS;j++)\n                sum += s[j] * filter[j];\n        }\n#endif\n        sum = sum >> FILTER_BITS;\n        if (sum < 0)\n            sum = 0;\n        else if (sum > 255)\n            sum = 255;\n        dst[0] = sum;\n        src_pos += src_incr;\n        dst++;\n    }\n}']