Message ID | 20230209105519.1814-4-ffmpeg@gyani.pro |
---|---|
State | New |
Headers | show |
Series | [FFmpeg-devel,v2,1/4] avformat: add av_program_copy() | expand |
Context | Check | Description |
---|---|---|
andriy/make_x86 | success | Make finished |
andriy/make_fate_x86 | fail | Make fate failed |
diff --git a/libavformat/tee.c b/libavformat/tee.c index dd408dd096..2fde8a3828 100644 --- a/libavformat/tee.c +++ b/libavformat/tee.c @@ -291,6 +291,12 @@ static int open_slave(AVFormatContext *avf, char *slave, TeeSlave *tee_slave) } } + for (i = 0; i < avf->nb_programs; i++) { + ret = av_program_copy(avf2, avf, avf->programs[i]->id, 0); + if (ret < 0) + av_log(avf, AV_LOG_WARNING, "unable to transfer program %d to child muxer\n", avf->programs[i]->id); + } + ret = ff_format_output_open(avf2, filename, &options); if (ret < 0) { av_log(avf, AV_LOG_ERROR, "Slave '%s': error opening: %s\n", slave,