Bug 1312980 - CID 1374148: Control flow issues (DEADCODE) in GetUserMediaCallbackMediaStreamListener::NotifyChromeOfTrackStops() draft
authorJames Cheng <jacheng@mozilla.com>
Wed, 26 Oct 2016 14:16:55 +0800
changeset 429601 47db0f10ee08be2eec2205d4d554786e083d87f4
parent 429594 f9f3cc95d7282f1fd83f66dd74acbcdbfe821915
child 535008 2b2456d573655be9f5b1eadb66f2a9c6e38c4e13
push id33611
push userbmo:jacheng@mozilla.com
push dateWed, 26 Oct 2016 06:17:35 +0000
bugs1312980, 1374148
milestone52.0a1
Bug 1312980 - CID 1374148: Control flow issues (DEADCODE) in GetUserMediaCallbackMediaStreamListener::NotifyChromeOfTrackStops() MozReview-Commit-ID: GDuY611PcVM
dom/media/MediaManager.cpp
--- a/dom/media/MediaManager.cpp
+++ b/dom/media/MediaManager.cpp
@@ -3623,17 +3623,17 @@ GetUserMediaCallbackMediaStreamListener:
   MOZ_ASSERT(!stopAudio || mAudioDevice,
              "If there's a pending stop for audio, there must be an audio device");
   MOZ_ASSERT(!stopVideo || !mVideoStopped,
              "If there's a pending stop for video, video must not have been stopped");
   MOZ_ASSERT(!stopVideo || mVideoDevice,
              "If there's a pending stop for video, there must be a video device");
 
   if ((stopAudio || mAudioStopped || !mAudioDevice) &&
-      (stopAudio || mVideoStopped || !mVideoDevice)) {
+      (stopVideo || mVideoStopped || !mVideoDevice)) {
     // All tracks stopped.
     Stop();
     return;
   }
 
   mAudioStopped |= stopAudio;
   mVideoStopped |= stopVideo;