Revision c5dcb3d4 libavformat/utils.c

View differences:

libavformat/utils.c
3091 3091

  
3092 3092
int av_interleaved_write_frame(AVFormatContext *s, AVPacket *pkt){
3093 3093
    AVStream *st= s->streams[ pkt->stream_index];
3094
    int ret;
3094 3095

  
3095 3096
    //FIXME/XXX/HACK drop zero sized packets
3096 3097
    if(st->codec->codec_type == AVMEDIA_TYPE_AUDIO && pkt->size==0)
......
3098 3099

  
3099 3100
    av_dlog(s, "av_interleaved_write_frame size:%d dts:%"PRId64" pts:%"PRId64"\n",
3100 3101
            pkt->size, pkt->dts, pkt->pts);
3101
    if(compute_pkt_fields2(s, st, pkt) < 0 && !(s->oformat->flags & AVFMT_NOTIMESTAMPS))
3102
        return -1;
3102
    if((ret = compute_pkt_fields2(s, st, pkt)) < 0 && !(s->oformat->flags & AVFMT_NOTIMESTAMPS))
3103
        return ret;
3103 3104

  
3104 3105
    if(pkt->dts == AV_NOPTS_VALUE && !(s->oformat->flags & AVFMT_NOTIMESTAMPS))
3105
        return -1;
3106
        return AVERROR(EINVAL);
3106 3107

  
3107 3108
    for(;;){
3108 3109
        AVPacket opkt;

Also available in: Unified diff