[3/5] flvdec: Remove the now redundant check for known broken metadata creator

Message ID 1329903034-45259-3-git-send-email-martin@martin.st
State Superseded
Headers show

Commit Message

Martin Storsjö Feb. 22, 2012, 9:30 a.m.
From: Michael Niedermayer <michaelni@gmx.at>

The index validation identifies these indexes as broken.
---
 libavformat/flvdec.c |   12 ------------
 1 files changed, 0 insertions(+), 12 deletions(-)

Patch

diff --git a/libavformat/flvdec.c b/libavformat/flvdec.c
index c652baa..b34f0bf 100644
--- a/libavformat/flvdec.c
+++ b/libavformat/flvdec.c
@@ -144,18 +144,6 @@  static int parse_keyframes_index(AVFormatContext *s, AVIOContext *ioc, AVStream
     int64_t *filepositions = NULL;
     int ret = AVERROR(ENOSYS);
     int64_t initial_pos = avio_tell(ioc);
-    AVDictionaryEntry *creator = av_dict_get(s->metadata, "metadatacreator",
-                                             NULL, 0);
-
-    if (creator && !strcmp(creator->value, "MEGA")) {
-        /* Files with this metadatacreator tag seem to have filepositions
-         * pointing at the 4 trailer bytes of the previous packet,
-         * which isn't the norm (nor what we expect here, nor what
-         * jwplayer + lighttpd expect, nor what flvtool2 produces).
-         * Just ignore the index in this case, instead of risking trying
-         * to adjust it to something that might or might not work. */
-        return 0;
-    }
 
     while (avio_tell(ioc) < max_pos - 2 && amf_get_string(ioc, str_val, sizeof(str_val)) > 0) {
         int64_t* current_array;