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

libavformat/segment.c:314:11: Call
312.     }
313. 
314.     ret = ff_write_chained(oc, pkt->stream_index, pkt, s);
               ^
315. 
316. fail:

libavformat/mux.c:640:12: Call
  638.                                      src->streams[pkt->stream_index]->time_base,
  639.                                      dst->streams[dst_stream]->time_base);
  640.     return av_write_frame(dst, &local_pkt);
                  ^
  641. }

libavformat/mux.c:438:9: Assignment
    436. 
    437.     if (ret >= 0)
    438.         s->streams[pkt->stream_index]->nb_frames++;
                 ^
    439.     return ret;
    440. }

libavformat/segment.c:320:9: Call
318.         if (seg->list)
319.             avio_close(seg->pb);
320.         avformat_free_context(oc);
             ^
321.     }
322. 

libavformat/utils.c:2494:1: <LHS trace>
2492. }
2493. 
2494. void avformat_free_context(AVFormatContext *s)
      ^
2495. {
2496.     int i;

libavformat/utils.c:2494:1: Parameter `s->nb_programs`
  2492. }
  2493. 
  2494. void avformat_free_context(AVFormatContext *s)
        ^
  2495. {
  2496.     int i;

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