avformat/matroskadec: Remove redundant setting of chapter titles
authorAndreas Rheinhardt <andreas.rheinhardt@gmail.com>
Mon, 13 Apr 2020 19:56:47 +0000 (21:56 +0200)
committerAndreas Rheinhardt <andreas.rheinhardt@gmail.com>
Sat, 18 Apr 2020 22:33:34 +0000 (00:33 +0200)
Chapter titles are added to the chapter's metadata since 6cb6e159,
yet since 012867f0 (the predecessor of) avpriv_new_chapter() already
adds the title to the chapter's metadata. So setting it again in
matroskadec.c is redundant and expensive.

Signed-off-by: Andreas Rheinhardt <andreas.rheinhardt@gmail.com>
libavformat/matroskadec.c

index c699ce6..761d8b3 100644 (file)
@@ -2933,10 +2933,6 @@ static int matroska_read_header(AVFormatContext *s)
                                    (AVRational) { 1, 1000000000 },
                                    chapters[i].start, chapters[i].end,
                                    chapters[i].title);
-            if (chapters[i].chapter) {
-                av_dict_set(&chapters[i].chapter->metadata,
-                            "title", chapters[i].title, 0);
-            }
             max_start = chapters[i].start;
         }