libavcodec/ac3enc.c:2377: error: Buffer Overrun L2
  Offset: [1, max(7, `avctx->priv_data->fbw_channels`)] Size: 7 by call to `set_bandwidth`.

libavcodec/ac3enc.c:2321:9: Parameter `avctx->priv_data->fbw_channels`
2319.  * Initialize the encoder.
2320.  */
2321. av_cold int ff_ac3_encode_init(AVCodecContext *avctx)
              ^
2322. {
2323.     AC3EncodeContext *s = avctx->priv_data;

libavcodec/ac3enc.c:2332:11: Call
2330.     ff_ac3_common_init();
2331. 
2332.     ret = validate_options(avctx, s);
                ^
2333.     if (ret)
2334.         return ret;

libavcodec/ac3enc.c:2019:1: Parameter `s->fbw_channels`
  2017. 
  2018. 
  2019. static av_cold int validate_options(AVCodecContext *avctx, AC3EncodeContext *s)
        ^
  2020. {
  2021.     int i, ret, max_sr;

libavcodec/ac3enc.c:2029:11: Call
  2027.                                       "might be incorrect.\n");
  2028.     }
  2029.     ret = set_channel_info(s, avctx->channels, &avctx->channel_layout);
                  ^
  2030.     if (ret) {
  2031.         av_log(avctx, AV_LOG_ERROR, "invalid channel layout\n");

libavcodec/ac3enc.c:1974:1: Parameter `s->fbw_channels`
    1972.  * Set channel information during initialization.
    1973.  */
    1974. static av_cold int set_channel_info(AC3EncodeContext *s, int channels,
          ^
    1975.                                     int64_t *channel_layout)
    1976. {

libavcodec/ac3enc.c:2377:5: Call
2375.         s->output_frame_header = ac3_output_frame_header;
2376. 
2377.     set_bandwidth(s);
          ^
2378. 
2379.     exponent_init(s);

libavcodec/ac3enc.c:2145:1: <Offset trace>
2143.  * default value will be used.
2144.  */
2145. static av_cold void set_bandwidth(AC3EncodeContext *s)
      ^
2146. {
2147.     int blk, ch;

libavcodec/ac3enc.c:2145:1: Parameter `s->fbw_channels`
  2143.  * default value will be used.
  2144.  */
  2145. static av_cold void set_bandwidth(AC3EncodeContext *s)
        ^
  2146. {
  2147.     int blk, ch;

libavcodec/ac3enc.c:2145:1: <Length trace>
2143.  * default value will be used.
2144.  */
2145. static av_cold void set_bandwidth(AC3EncodeContext *s)
      ^
2146. {
2147.     int blk, ch;

libavcodec/ac3enc.c:2145:1: Parameter `s->start_freq[*]`
  2143.  * default value will be used.
  2144.  */
  2145. static av_cold void set_bandwidth(AC3EncodeContext *s)
        ^
  2146. {
  2147.     int blk, ch;

libavcodec/ac3enc.c:2162:9: Array access: Offset: [1, max(7, avctx->priv_data->fbw_channels)] Size: 7 by call to `set_bandwidth` 
  2160.     /* set number of coefficients for each channel */
  2161.     for (ch = 1; ch <= s->fbw_channels; ch++) {
  2162.         s->start_freq[ch] = 0;
                ^
  2163.         for (blk = 0; blk < AC3_MAX_BLOCKS; blk++)
  2164.             s->blocks[blk].end_freq[ch] = s->bandwidth_code * 3 + 73;
