libavformat/mpegtsenc.c:667: error: Buffer Overrun L2
  Offset added: [5, 371] (⇐ [4, 187] + [1, 184]) Size: 188 by call to `mpegts_write_pes`.

libavformat/mpegtsenc.c:667:13: Call
665.         ts_st = st->priv_data;
666.         if (ts_st->payload_index > 0) {
667.             mpegts_write_pes(s, st, ts_st->payload, ts_st->payload_index,
                 ^
668.                              ts_st->payload_pts, ts_st->payload_dts);
669.         }

libavformat/mpegtsenc.c:480:1: Parameter `st->priv_data->pid`
  478. 
  479. /* NOTE: pes_data contains all the PES packet */
  480. static void mpegts_write_pes(AVFormatContext *s, AVStream *st,
       ^
  481.                              const uint8_t *payload, int payload_size,
  482.                              int64_t pts, int64_t dts)

libavformat/mpegtsenc.c:667:13: Call
665.         ts_st = st->priv_data;
666.         if (ts_st->payload_index > 0) {
667.             mpegts_write_pes(s, st, ts_st->payload, ts_st->payload_index,
                 ^
668.                              ts_st->payload_pts, ts_st->payload_dts);
669.         }

libavformat/mpegtsenc.c:480:1: <Offset trace>
478. 
479. /* NOTE: pes_data contains all the PES packet */
480. static void mpegts_write_pes(AVFormatContext *s, AVStream *st,
     ^
481.                              const uint8_t *payload, int payload_size,
482.                              int64_t pts, int64_t dts)

libavformat/mpegtsenc.c:480:1: Parameter `payload_size`
  478. 
  479. /* NOTE: pes_data contains all the PES packet */
  480. static void mpegts_write_pes(AVFormatContext *s, AVStream *st,
       ^
  481.                              const uint8_t *payload, int payload_size,
  482.                              int64_t pts, int64_t dts)

libavformat/mpegtsenc.c:480:1: <Length trace>
478. 
479. /* NOTE: pes_data contains all the PES packet */
480. static void mpegts_write_pes(AVFormatContext *s, AVStream *st,
     ^
481.                              const uint8_t *payload, int payload_size,
482.                              int64_t pts, int64_t dts)

libavformat/mpegtsenc.c:480:1: Array declaration
  478. 
  479. /* NOTE: pes_data contains all the PES packet */
  480. static void mpegts_write_pes(AVFormatContext *s, AVStream *st,
       ^
  481.                              const uint8_t *payload, int payload_size,
  482.                              int64_t pts, int64_t dts)

libavformat/mpegtsenc.c:608:9: Array access: Offset added: [5, 371] (⇐ [4, 187] + [1, 184]) Size: 188 by call to `mpegts_write_pes` 
  606.             }
  607.         }
  608.         memcpy(buf + TS_PACKET_SIZE - len, payload, len);
               ^
  609.         payload += len;
  610.         payload_size -= len;
