diff mbox series

[FFmpeg-devel,19/41] avformat/segment: Deduplicate AVClasses

Message ID VI1PR0301MB2159505F43C7F18D9E0C26E58F0E9@VI1PR0301MB2159.eurprd03.prod.outlook.com
State Accepted
Commit 072496ca40b03f8c7c46498f739e4246199426bb
Headers show
Series [FFmpeg-devel,01/41] avformat/Makefile: Add missing rawdec dependency for IPU demuxer
Related show

Checks

Context Check Description
andriy/x86_make success Make finished
andriy/x86_make_fate success Make fate finished
andriy/PPC64_make success Make finished
andriy/PPC64_make_fate success Make fate finished

Commit Message

Andreas Rheinhardt June 17, 2021, 2:31 a.m. UTC
The child_class_next API relied on different (de)muxers to use
different AVClasses; yet this API has been replaced by
child_class_iterate.

Signed-off-by: Andreas Rheinhardt <andreas.rheinhardt@outlook.com>
---
 libavformat/segment.c | 13 +++----------
 1 file changed, 3 insertions(+), 10 deletions(-)
diff mbox series

Patch

diff --git a/libavformat/segment.c b/libavformat/segment.c
index 24490f1280..ed671353d0 100644
--- a/libavformat/segment.c
+++ b/libavformat/segment.c
@@ -1045,14 +1045,14 @@  static const AVOption options[] = {
     { NULL },
 };
 
-#if CONFIG_SEGMENT_MUXER
 static const AVClass seg_class = {
-    .class_name = "segment muxer",
+    .class_name = "(stream) segment muxer",
     .item_name  = av_default_item_name,
     .option     = options,
     .version    = LIBAVUTIL_VERSION_INT,
 };
 
+#if CONFIG_SEGMENT_MUXER
 const AVOutputFormat ff_segment_muxer = {
     .name           = "segment",
     .long_name      = NULL_IF_CONFIG_SMALL("segment"),
@@ -1069,13 +1069,6 @@  const AVOutputFormat ff_segment_muxer = {
 #endif
 
 #if CONFIG_STREAM_SEGMENT_MUXER
-static const AVClass sseg_class = {
-    .class_name = "stream_segment muxer",
-    .item_name  = av_default_item_name,
-    .option     = options,
-    .version    = LIBAVUTIL_VERSION_INT,
-};
-
 const AVOutputFormat ff_stream_segment_muxer = {
     .name           = "stream_segment,ssegment",
     .long_name      = NULL_IF_CONFIG_SMALL("streaming segment muxer"),
@@ -1087,6 +1080,6 @@  const AVOutputFormat ff_stream_segment_muxer = {
     .write_trailer  = seg_write_trailer,
     .deinit         = seg_free,
     .check_bitstream = seg_check_bitstream,
-    .priv_class     = &sseg_class,
+    .priv_class     = &seg_class,
 };
 #endif