Bug 1113086 - AudioChannel policy in Browser API - patch 7 - DOMCamera fix CLOSED TREE
☠☠ backed out by aa043f7e701f ☠ ☠
authorAndrea Marchesini <amarchesini@mozilla.com>
Thu, 18 Jun 2015 16:18:09 +0100
changeset 267710 eb7e79a2c9e944a4c35b658f19983111a51ae82d
parent 267709 513444d716e8e8051ac7924d1caf474756c8a784
child 267711 26a04a373ecc17ff288ac9a63d4cf4a293c6ec65
push id4932
push userjlund@mozilla.com
push dateMon, 10 Aug 2015 18:23:06 +0000
treeherdermozilla-esr52@6dd5a4f5f745 [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
bugs1113086
milestone41.0a1
Bug 1113086 - AudioChannel policy in Browser API - patch 7 - DOMCamera fix CLOSED TREE
dom/camera/DOMCameraControl.cpp
--- a/dom/camera/DOMCameraControl.cpp
+++ b/dom/camera/DOMCameraControl.cpp
@@ -1068,19 +1068,19 @@ nsDOMCameraControl::NotifyRecordingStatu
       return NS_ERROR_UNEXPECTED;
     }
 
     // Camera app will stop recording when it falls to the background, so no callback is necessary.
     mAudioChannelAgent->Init(mWindow, (int32_t)AudioChannel::Content, nullptr);
     // Video recording doesn't output any sound, so it's not necessary to check canPlay.
     float volume = 0.0;
     bool muted = true;
-    aRv = mAudioChannelAgent->StartPlaying(&volume, &muted);
-    if (NS_WARN_IF(aRv.Failed())) {
-      return nullptr;
+    rv = mAudioChannelAgent->StartPlaying(&volume, &muted);
+    if (NS_WARN_IF(NS_FAILED(rv))) {
+      return rv;
     }
   }
 #endif
   return rv;
 }
 
 already_AddRefed<Promise>
 nsDOMCameraControl::CreatePromise(ErrorResult& aRv)