Revision 76432655

View differences:

libavformat/nutenc.c
588 588
        nut->chapter  = av_mallocz(sizeof(ChapterContext)*s->nb_chapters);
589 589
    nut->time_base= av_mallocz(sizeof(AVRational   )*(s->nb_streams +
590 590
                                                      s->nb_chapters));
591
    if (!nut->stream || (s->nb_chapters && !nut->chapter) || !nut->time_base) {
592
        av_freep(&nut->stream);
593
        av_freep(&nut->chapter);
594
        av_freep(&nut->time_base);
595
        return AVERROR(ENOMEM);
596
    }
591 597

  
592 598
    for(i=0; i<s->nb_streams; i++){
593 599
        AVStream *st= s->streams[i];

Also available in: Unified diff