Bug 1403129 - Don't cache decoder's description. r=gerald
authorJean-Yves Avenard <jyavenard@mozilla.com>
Tue, 26 Sep 2017 15:26:34 +0200
changeset 383238 11a1367ea526f70f7b8def6547614aa4718b3339
parent 383237 ddb02772078ec30849fa8299953d465643416d49
child 383239 f2b1824179f8f72ce2bae50bfb9bb6dd80d4d555
push id95539
push userkwierso@gmail.com
push dateThu, 28 Sep 2017 00:01:12 +0000
treeherdermozilla-inbound@72de90e66155 [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewersgerald
bugs1403129
milestone58.0a1
first release with
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
last release without
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
Bug 1403129 - Don't cache decoder's description. r=gerald MozReview-Commit-ID: 5ULVmUWUBGk
dom/media/MediaFormatReader.cpp
--- a/dom/media/MediaFormatReader.cpp
+++ b/dom/media/MediaFormatReader.cpp
@@ -3126,22 +3126,26 @@ MediaFormatReader::GetMozDebugReaderData
   nsCString result;
   nsAutoCString audioDecoderName("unavailable");
   nsAutoCString videoDecoderName = audioDecoderName;
   nsAutoCString audioType("none");
   nsAutoCString videoType("none");
 
   if (HasAudio()) {
     MutexAutoLock lock(mAudio.mMutex);
-    audioDecoderName = mAudio.mDescription;
+    audioDecoderName = mAudio.mDecoder
+                       ? mAudio.mDecoder->GetDescriptionName()
+                       : mAudio.mDescription;
     audioType = mInfo.mAudio.mMimeType;
   }
   if (HasVideo()) {
     MutexAutoLock mon(mVideo.mMutex);
-    videoDecoderName = mVideo.mDescription;
+    videoDecoderName = mVideo.mDecoder
+                       ? mVideo.mDecoder->GetDescriptionName()
+                       : mVideo.mDescription;
     videoType = mInfo.mVideo.mMimeType;
   }
 
   result += nsPrintfCString(
     "Audio Decoder(%s): %s\n", audioType.get(), audioDecoderName.get());
   result += nsPrintfCString("Audio Frames Decoded: %" PRIu64 "\n",
                             mAudio.mNumSamplesOutputTotal);
   if (HasAudio()) {