libavformat/hlsenc.c:305: error: Integer Overflow L2
  ([0, +oo] - 1):unsigned32 by call to `avformat_free_context`.

libavformat/hlsenc.c:304:5: Call
302. 
303.     av_write_trailer(oc);
304.     avio_closep(&oc->pb);
         ^
305.     avformat_free_context(oc);
306.     av_free(hls->basename);

libavformat/aviobuf.c:810:15: Call
  808. int avio_closep(AVIOContext **s)
  809. {
  810.     int ret = avio_close(*s);
                     ^
  811.     *s = NULL;
  812.     return ret;

libavformat/aviobuf.c:794:1: Parameter `s->opaque->is_connected`
    792. }
    793. 
    794. int avio_close(AVIOContext *s)
         ^
    795. {
    796.     URLContext *h;

libavformat/hlsenc.c:305:5: Call
303.     av_write_trailer(oc);
304.     avio_closep(&oc->pb);
305.     avformat_free_context(oc);
         ^
306.     av_free(hls->basename);
307.     append_entry(hls, hls->duration);

libavformat/utils.c:2595:1: <LHS trace>
2593. }
2594. 
2595. void avformat_free_context(AVFormatContext *s)
      ^
2596. {
2597.     int i;

libavformat/utils.c:2595:1: Parameter `s->nb_programs`
  2593. }
  2594. 
  2595. void avformat_free_context(AVFormatContext *s)
        ^
  2596. {
  2597.     int i;

libavformat/utils.c:2622:10: Binary operation: ([0, +oo] - 1):unsigned32 by call to `avformat_free_context` 
  2620.         av_free(st);
  2621.     }
  2622.     for (i = s->nb_programs - 1; i >= 0; i--) {
                 ^
  2623.         av_dict_free(&s->programs[i]->metadata);
  2624.         av_freep(&s->programs[i]->stream_index);
