Skip to content

Commit

Permalink
lavf/utils: dont't explicitly check AVIOContext.error
Browse files Browse the repository at this point in the history
The error should be caught in write_packet()/write_trailer()

Signed-off-by: Ronald S. Bultje <[email protected]>
  • Loading branch information
elenril authored and rbultje committed Mar 15, 2011
1 parent 025225d commit 75b9ed0
Showing 1 changed file with 0 additions and 8 deletions.
8 changes: 0 additions & 8 deletions libavformat/utils.c
Original file line number Diff line number Diff line change
Expand Up @@ -2988,8 +2988,6 @@ int av_write_frame(AVFormatContext *s, AVPacket *pkt)
return ret;

ret= s->oformat->write_packet(s, pkt);
if(!ret)
ret= url_ferror(s->pb);
return ret;
}

Expand Down Expand Up @@ -3111,8 +3109,6 @@ int av_interleaved_write_frame(AVFormatContext *s, AVPacket *pkt){

if(ret<0)
return ret;
if(url_ferror(s->pb))
return url_ferror(s->pb);
}
}

Expand All @@ -3134,15 +3130,11 @@ int av_write_trailer(AVFormatContext *s)

if(ret<0)
goto fail;
if(url_ferror(s->pb))
goto fail;
}

if(s->oformat->write_trailer)
ret = s->oformat->write_trailer(s);
fail:
if(ret == 0)
ret=url_ferror(s->pb);
for(i=0;i<s->nb_streams;i++) {
av_freep(&s->streams[i]->priv_data);
av_freep(&s->streams[i]->index_entries);
Expand Down

0 comments on commit 75b9ed0

Please sign in to comment.