ffmpeg.c:986: error: Buffer Overrun L2
  Offset: [0, 255] Size: 8 by call to `sws_scale`.

ffmpeg.c:860:1: Parameter `in_picture->data[*]`
858. static uint8_t *bit_buffer= NULL;
859. 
860. static void do_video_out(AVFormatContext *s,
     ^
861.                          AVOutputStream *ost,
862.                          AVInputStream *ist,

ffmpeg.c:986:9: Call
984.             }
985.         }
986.         sws_scale(ost->img_resample_ctx, formatted_picture->data, formatted_picture->linesize,
             ^
987.               0, ost->resample_height, resampling_dst->data, resampling_dst->linesize);
988.     }

libswscale/swscale.c:3085:14: <Offset trace>
3083. 
3084.     if (usePal(c->srcFormat)) {
3085.         for (i=0; i<256; i++) {
                   ^
3086.             int p, r, g, b,y,u,v;
3087.             if(c->srcFormat == PIX_FMT_PAL8) {

libswscale/swscale.c:3085:14: Assignment
  3083. 
  3084.     if (usePal(c->srcFormat)) {
  3085.         for (i=0; i<256; i++) {
                     ^
  3086.             int p, r, g, b,y,u,v;
  3087.             if(c->srcFormat == PIX_FMT_PAL8) {

libswscale/swscale.c:3069:1: <Length trace>
3067.  * Assumes planar YUV to be in YUV order instead of YVU.
3068.  */
3069. int sws_scale(SwsContext *c, uint8_t* src[], int srcStride[], int srcSliceY,
      ^
3070.               int srcSliceH, uint8_t* dst[], int dstStride[])
3071. {

libswscale/swscale.c:3069:1: Parameter `**src`
  3067.  * Assumes planar YUV to be in YUV order instead of YVU.
  3068.  */
  3069. int sws_scale(SwsContext *c, uint8_t* src[], int srcStride[], int srcSliceY,
        ^
  3070.               int srcSliceH, uint8_t* dst[], int dstStride[])
  3071. {

libswscale/swscale.c:3088:19: Array access: Offset: [0, 255] Size: 8 by call to `sws_scale` 
  3086.             int p, r, g, b,y,u,v;
  3087.             if(c->srcFormat == PIX_FMT_PAL8) {
  3088.                 p=((uint32_t*)(src[1]))[i];
                          ^
  3089.                 r= (p>>16)&0xFF;
  3090.                 g= (p>> 8)&0xFF;
