Message ID | 20200302044445.14842-6-andreas.rheinhardt@gmail.com |
---|---|
State | Accepted |
Headers | show |
Series | [FFmpeg-devel,1/17] avformat: Use correct error in case muxer is not found | expand |
Context | Check | Description |
---|---|---|
andriy/ffmpeg-patchwork | success | Make fate finished |
diff --git a/libavformat/webm_chunk.c b/libavformat/webm_chunk.c index 3c00c562e5..3beb267458 100644 --- a/libavformat/webm_chunk.c +++ b/libavformat/webm_chunk.c @@ -72,10 +72,12 @@ static int chunk_mux_init(AVFormatContext *s) oc->interrupt_callback = s->interrupt_callback; oc->max_delay = s->max_delay; - oc->flags = s->flags; + oc->flags = s->flags & ~AVFMT_FLAG_FLUSH_PACKETS; oc->strict_std_compliance = s->strict_std_compliance; oc->avoid_negative_ts = s->avoid_negative_ts; + oc->flush_packets = 0; + av_dict_copy(&oc->metadata, s->metadata, 0); if (!(st = avformat_new_stream(oc, NULL)))
The webm_chunk muxer caches its output to a dynamic buffer and when it outputs anything, it explicitly flushes it. So set the flags indicating that flushing after each packet should not be done automatically (basically avoiding avio_write_marker() to be called by flush_if_needed() in libavformat/mux.c). Signed-off-by: Andreas Rheinhardt <andreas.rheinhardt@gmail.com> --- libavformat/webm_chunk.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-)