Message ID | 20201108195043.210799-2-andriy.gelman@gmail.com |
---|---|
State | New |
Headers | show |
Series | [FFmpeg-devel,1/4] avformat/nutenc: don't use header_count to store different variables | expand |
Context | Check | Description |
---|---|---|
andriy/x86_make | success | Make finished |
andriy/x86_make_fate | success | Make fate finished |
diff --git a/libavformat/nutenc.c b/libavformat/nutenc.c index 87adef6f7e..0646f72af2 100644 --- a/libavformat/nutenc.c +++ b/libavformat/nutenc.c @@ -988,8 +988,11 @@ static int nut_write_packet(AVFormatContext *s, AVPacket *pkt) data_size += sm_size; } - if (1LL << (20 + 3 * nut->header_rep_count) <= avio_tell(bc)) - write_headers(s, bc); + if (1LL << (20 + 3 * nut->header_rep_count) <= avio_tell(bc)) { + ret = write_headers(s, bc); + if (ret < 0) + goto fail; + } if (key_frame && !(nus->last_flags & FLAG_KEY)) store_sp = 1;