Commit 270f94e1 authored by Moritz Barsnick's avatar Moritz Barsnick Committed by Michael Niedermayer

avformat/rtpenc_mpegts: copy metadata to mpegts sub-muxer

Fixes #7293.
Signed-off-by: 's avatarMoritz Barsnick <barsnick@gmx.net>
Signed-off-by: 's avatarMichael Niedermayer <michael@niedermayer.cc>
parent 6390f52a
......@@ -60,6 +60,7 @@ static int rtp_mpegts_write_header(AVFormatContext *s)
return AVERROR(ENOMEM);
mpegts_ctx->oformat = mpegts_format;
mpegts_ctx->max_delay = s->max_delay;
av_dict_copy(&mpegts_ctx->metadata, s->metadata, 0);
for (i = 0; i < s->nb_streams; i++) {
AVStream* st = avformat_new_stream(mpegts_ctx, NULL);
if (!st)
......@@ -102,6 +103,7 @@ static int rtp_mpegts_write_header(AVFormatContext *s)
fail:
if (mpegts_ctx) {
ffio_free_dyn_buf(&mpegts_ctx->pb);
av_dict_free(&mpegts_ctx->metadata);
avformat_free_context(mpegts_ctx);
}
if (rtp_ctx)
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment