Bug 1289976. Part 2 - Remove the IsShutdown() check from MediaDecoder::DumpDebugInfo() which happens before Shutdown(). r=kaku
authorJW Wang <jwwang@mozilla.com>
Wed, 27 Jul 2016 10:33:50 +0800
changeset 333322 5e333fc275673c681e91631b1e8443f9fa8fd268
parent 333321 1fa73e3d834d10563f8667553f7a985a7583e182
child 333323 af2250994011d1934ebc92a6e9f92c21a1262a5d
push id10033
push userraliiev@mozilla.com
push dateMon, 19 Sep 2016 13:50:26 +0000
treeherdermozilla-aurora@5dddbefdf759 [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewerskaku
bugs1289976
milestone51.0a1
Bug 1289976. Part 2 - Remove the IsShutdown() check from MediaDecoder::DumpDebugInfo() which happens before Shutdown(). r=kaku MozReview-Commit-ID: HU3ybjFZMsE
dom/media/MediaDecoder.cpp
--- a/dom/media/MediaDecoder.cpp
+++ b/dom/media/MediaDecoder.cpp
@@ -1937,27 +1937,28 @@ MediaDecoder::NextFrameBufferedStatus()
   return GetBuffered().Contains(interval)
     ? MediaDecoderOwner::NEXT_FRAME_AVAILABLE
     : MediaDecoderOwner::NEXT_FRAME_UNAVAILABLE;
 }
 
 void
 MediaDecoder::DumpDebugInfo()
 {
+  MOZ_ASSERT(!IsShutdown());
   DUMP_LOG("metadata: channels=%u rate=%u hasAudio=%d hasVideo=%d, "
-           "state: mPlayState=%s mIsDormant=%d, IsShutdown()=%d",
+           "state: mPlayState=%s mIsDormant=%d",
            mInfo ? mInfo->mAudio.mChannels : 0, mInfo ? mInfo->mAudio.mRate : 0,
            mInfo ? mInfo->HasAudio() : 0, mInfo ? mInfo->HasVideo() : 0,
-           PlayStateStr(), mIsDormant, IsShutdown());
+           PlayStateStr(), mIsDormant);
 
   nsString str;
   GetMozDebugReaderData(str);
   DUMP_LOG("reader data:\n%s", NS_ConvertUTF16toUTF8(str).get());
 
-  if (!IsShutdown() && GetStateMachine()) {
+  if (GetStateMachine()) {
     GetStateMachine()->DumpDebugInfo();
   }
 }
 
 void
 MediaDecoder::NotifyAudibleStateChanged()
 {
   MOZ_ASSERT(!IsShutdown());