Bug 1384944 - Replace NS_ConvertASCIItoUTF16 by NS_ConvertUTF8toUTF16; r=padenot
authorChun-Min Chang <chun.m.chang@gmail.com>
Fri, 28 Jul 2017 15:41:20 +0800
changeset 421971 df430a961c90fdff52297d24380971d4980eecf9
parent 421970 78d41229c3398e9424723b16e9bca006fd9ba778
child 421972 a304408c275f7f503a078b144351e548e9cbab01
push id7761
push userjlund@mozilla.com
push dateFri, 15 Sep 2017 00:19:52 +0000
treeherdermozilla-beta@c38455951db4 [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewerspadenot
bugs1384944
milestone56.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 1384944 - Replace NS_ConvertASCIItoUTF16 by NS_ConvertUTF8toUTF16; r=padenot
dom/media/CubebUtils.cpp
--- a/dom/media/CubebUtils.cpp
+++ b/dom/media/CubebUtils.cpp
@@ -605,19 +605,19 @@ void GetDeviceCollection(nsTArray<RefPtr
     cubeb_device_collection collection = { nullptr, 0 };
     if (cubeb_enumerate_devices(context,
                                 aSide == Input ? CUBEB_DEVICE_TYPE_INPUT :
                                                  CUBEB_DEVICE_TYPE_OUTPUT,
                                 &collection) == CUBEB_OK) {
       for (unsigned int i = 0; i < collection.count; ++i) {
         auto device = collection.device[i];
         RefPtr<AudioDeviceInfo> info =
-          new AudioDeviceInfo(NS_ConvertASCIItoUTF16(device.friendly_name),
-                              NS_ConvertASCIItoUTF16(device.group_id),
-                              NS_ConvertASCIItoUTF16(device.vendor_name),
+          new AudioDeviceInfo(NS_ConvertUTF8toUTF16(device.friendly_name),
+                              NS_ConvertUTF8toUTF16(device.group_id),
+                              NS_ConvertUTF8toUTF16(device.vendor_name),
                               ConvertCubebType(device.type),
                               ConvertCubebState(device.state),
                               ConvertCubebPreferred(device.preferred),
                               ConvertCubebFormat(device.format),
                               ConvertCubebFormat(device.default_format),
                               device.max_channels,
                               device.default_rate,
                               device.max_rate,