Bug 1247056 - Report specific cubeb-init error code - r=jwwang
☠☠ backed out by 2ae91c5e5354 ☠ ☠
authorGerald Squelart <gsquelart@mozilla.com>
Wed, 07 Sep 2016 21:26:01 -0700
changeset 315053 be036a725d3a
parent 315052 344a41f87a23
child 315054 2b3dce1c98f6
push id82043
push usergsquelart@mozilla.com
push dateFri, 23 Sep 2016 11:29:56 +0000
treeherdermozilla-inbound@13434fa439d1 [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewersjwwang
bugs1247056
milestone52.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 1247056 - Report specific cubeb-init error code - r=jwwang MozReview-Commit-ID: AqR2jKKtNHL
dom/media/AudioStream.cpp
--- a/dom/media/AudioStream.cpp
+++ b/dom/media/AudioStream.cpp
@@ -346,17 +346,17 @@ AudioStream::Init(uint32_t aNumChannels,
 
   params.format = ToCubebFormat<AUDIO_OUTPUT_FORMAT>::value;
   mAudioClock.Init(aRate);
 
   cubeb* cubebContext = CubebUtils::GetCubebContext();
   if (!cubebContext) {
     NS_WARNING("Can't get cubeb context!");
     CubebUtils::ReportCubebStreamInitFailure(true);
-    return NS_ERROR_FAILURE;
+    return NS_ERROR_DOM_MEDIA_CUBEB_INITIALIZATION_ERR;
   }
 
   return OpenCubeb(cubebContext, params, startTime, CubebUtils::GetFirstStream());
 }
 
 nsresult
 AudioStream::OpenCubeb(cubeb* aContext, cubeb_stream_params& aParams,
                        TimeStamp aStartTime, bool aIsFirst)