Bug 1223655 - Also don't check time of data end if track has ended. r=jesup a=sylvestre
authorAndreas Pehrson <pehrsons@gmail.com>
Mon, 28 Dec 2015 08:54:48 -0800
changeset 310539 0786a97aee59b4d3f32c35351c92c4be858d7e55
parent 310538 5628bb302871093c80ec07151250cdf7873df3d3
child 310540 ebc0418a8110c06695b315c1c78aba96ad4a5c62
push id5513
push userraliiev@mozilla.com
push dateMon, 25 Jan 2016 13:55:34 +0000
treeherdermozilla-beta@5ee97dd05b5c [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewersjesup, sylvestre
bugs1223655
milestone45.0a2
Bug 1223655 - Also don't check time of data end if track has ended. r=jesup a=sylvestre
dom/media/webrtc/MediaEngineDefault.h
--- a/dom/media/webrtc/MediaEngineDefault.h
+++ b/dom/media/webrtc/MediaEngineDefault.h
@@ -131,19 +131,22 @@ public:
                           bool aNoiseOn, uint32_t aNoise,
                           int32_t aPlayoutDelay) override { return NS_OK; };
   void AppendToSegment(AudioSegment& aSegment, TrackTicks aSamples);
   virtual void NotifyPull(MediaStreamGraph* aGraph,
                           SourceMediaStream *aSource,
                           TrackID aId,
                           StreamTime aDesiredTime) override
   {
-    NS_WARN_IF_FALSE(!aSource->FindTrack(aId) ||
+#ifdef DEBUG
+    StreamBuffer::Track* data = aSource->FindTrack(aId);
+    NS_WARN_IF_FALSE(!data || data->IsEnded() ||
                      aDesiredTime <= aSource->GetEndOfAppendedData(aId),
                      "MediaEngineDefaultAudioSource data underrun");
+#endif
   }
 
   virtual bool IsFake() override {
     return true;
   }
 
   virtual const dom::MediaSourceEnum GetMediaSource() override {
     return dom::MediaSourceEnum::Microphone;