diff mbox series

[FFmpeg-devel,18/29] avformat/asfenc: Deduplicate codec tags lists

Message ID 20210218034214.2090223-18-andreas.rheinhardt@gmail.com
State Accepted
Commit c50c85911ef7a6496953afe9975115139e49b187
Headers show
Series [FFmpeg-devel,01/29] configure, libavcodec/Makefile: Remove spurious CAF demuxer dependencies
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 Feb. 18, 2021, 3:42 a.m. UTC
Also saves relocations.

Signed-off-by: Andreas Rheinhardt <andreas.rheinhardt@gmail.com>
---
 libavformat/asfenc.c | 12 ++++++------
 1 file changed, 6 insertions(+), 6 deletions(-)
diff mbox series

Patch

diff --git a/libavformat/asfenc.c b/libavformat/asfenc.c
index 8b24264c94..23a09efe05 100644
--- a/libavformat/asfenc.c
+++ b/libavformat/asfenc.c
@@ -258,6 +258,10 @@  static const AVCodecTag codec_asf_bmp_tags[] = {
     { AV_CODEC_ID_NONE,      0 },
 };
 
+static const AVCodecTag *const asf_codec_tags[] = {
+        codec_asf_bmp_tags, ff_codec_bmp_tags, ff_codec_wav_tags, NULL
+};
+
 #define PREROLL_TIME 3100
 
 static void put_str16(AVIOContext *s, const char *tag)
@@ -1170,9 +1174,7 @@  AVOutputFormat ff_asf_muxer = {
     .write_packet   = asf_write_packet,
     .write_trailer  = asf_write_trailer,
     .flags          = AVFMT_GLOBALHEADER,
-    .codec_tag      = (const AVCodecTag * const []) {
-        codec_asf_bmp_tags, ff_codec_bmp_tags, ff_codec_wav_tags, 0
-    },
+    .codec_tag      = asf_codec_tags,
     .priv_class        = &asf_muxer_class,
 };
 #endif /* CONFIG_ASF_MUXER */
@@ -1197,9 +1199,7 @@  AVOutputFormat ff_asf_stream_muxer = {
     .write_packet   = asf_write_packet,
     .write_trailer  = asf_write_trailer,
     .flags          = AVFMT_GLOBALHEADER,
-    .codec_tag      = (const AVCodecTag * const []) {
-        codec_asf_bmp_tags, ff_codec_bmp_tags, ff_codec_wav_tags, 0
-    },
+    .codec_tag      = asf_codec_tags,
     .priv_class        = &asf_stream_muxer_class,
 };
 #endif /* CONFIG_ASF_STREAM_MUXER */