diff mbox series

[FFmpeg-devel,1/5] avformat/demux: Copy AVCodecContext properties in codec_close()

Message ID 20240705052555.402920-2-marth64@proxyid.net
State New
Headers show
Series Fix probing display of stream codec properties | expand


Context Check Description
yinshiyou/make_loongarch64 success Make finished
yinshiyou/make_fate_loongarch64 fail Make fate failed
andriy/make_x86 success Make finished
andriy/make_fate_x86 success Make fate finished

Commit Message

Marth64 July 5, 2024, 5:25 a.m. UTC
After avformat_find_stream_info() calls codec_close(), the
properties are not copied in the newly created skeleton context
returned by codec_close(). This breaks display of the properties
when viewing stream information afterward e.g. via av_dump_format().

Copy the old properties over, thus fixing printing of the properties
(such as Closed Captions) in av_dump_format() that broke sometime
after 4.4.2.

Signed-off-by: Marth64 <marth64@proxyid.net>
 libavformat/demux.c | 1 +
 1 file changed, 1 insertion(+)
diff mbox series


diff --git a/libavformat/demux.c b/libavformat/demux.c
index dc65f9ad91..72d4ae7593 100644
--- a/libavformat/demux.c
+++ b/libavformat/demux.c
@@ -1298,6 +1298,7 @@  static int codec_close(FFStream *sti)
     if (ret < 0)
         goto fail;
+    avctx_new->properties   = sti->avctx->properties;
     avctx_new->pkt_timebase = sti->avctx->pkt_timebase;