ffmpeg.c:465: error: Integer Overflow L2
  ([0, +oo] - 1):unsigned32 by call to `avformat_free_context`.

ffmpeg.c:465:9: Call
463.         if (!(s->oformat->flags & AVFMT_NOFILE) && s->pb)
464.             avio_close(s->pb);
465.         avformat_free_context(s);
             ^
466.         av_free(output_streams_for_file[i]);
467.     }

libavformat/utils.c:2548:1: <LHS trace>
2546. }
2547. 
2548. void avformat_free_context(AVFormatContext *s)
      ^
2549. {
2550.     int i;

libavformat/utils.c:2548:1: Parameter `s->nb_programs`
  2546. }
  2547. 
  2548. void avformat_free_context(AVFormatContext *s)
        ^
  2549. {
  2550.     int i;

libavformat/utils.c:2573:9: Binary operation: ([0, +oo] - 1):unsigned32 by call to `avformat_free_context` 
  2571.         av_free(st);
  2572.     }
  2573.     for(i=s->nb_programs-1; i>=0; i--) {
                ^
  2574.         av_dict_free(&s->programs[i]->metadata);
  2575.         av_freep(&s->programs[i]->stream_index);
