OSDN Git Service

Revert "FFmpegExtractor: Don't use our extractor when we agree with StageFright"
authorChristopher R. Palmer <crpalmer@gmail.com>
Mon, 5 Jun 2017 10:24:43 +0000 (06:24 -0400)
committerChristopher R. Palmer <crpalmer@gmail.com>
Mon, 5 Jun 2017 10:52:20 +0000 (06:52 -0400)
This reverts commit 40898770dd66b011b0a7653e1cd5750f176be038.

Change-Id: Ic57879f0dc22f1495e4c42d008529396929abd3d

extractor/FFmpegExtractor.cpp

index 6c41ca1..2a796ad 100644 (file)
@@ -2192,14 +2192,11 @@ bool SniffFFMPEG(
         ALOGV("sniff through BetterSniffFFMPEG success");
     }
 
-    if (mimeType != NULL && container != NULL && *mimeType == container) {
-        ALOGD("SniffFFMPEG sniffed the same thing as StageFright, use their extractor instead");
-        goto fail;
-    }
-
     if (container == NULL) {
         ALOGD("SniffFFMPEG failed to sniff this source");
-        goto fail;
+        (*meta)->clear();
+        *meta = NULL;
+        return false;
     }
 
     ALOGD("ffmpeg detected media content as '%s' with confidence %.2f",
@@ -2225,11 +2222,6 @@ bool SniffFFMPEG(
     }
 
     return true;
-
-fail:
-    (*meta)->clear();
-    *meta = NULL;
-    return false;
 }
 
 MediaExtractor *CreateFFMPEGExtractor(const sp<DataSource> &source, const char *mime, const sp<AMessage> &meta) {