merge b2g-inbound to mozilla-central

This commit is contained in:
Carsten "Tomcat" Book 2013-12-18 12:35:21 +01:00
commit ca14938a7f
2 changed files with 6 additions and 5 deletions

View File

@ -1,4 +1,4 @@
{
"revision": "2cc6e0988688b33fa46e3a05a726fb7919d7420e",
"revision": "7412c36923b59f6e4d7076de5be7e6ded6ddc586",
"repo_path": "/integration/gaia-central"
}

View File

@ -246,7 +246,8 @@ void
StringToBdAddressType(const nsAString& aBdAddress,
bt_bdaddr_t *aRetBdAddressType)
{
const char* str = NS_ConvertUTF16toUTF8(aBdAddress).get();
NS_ConvertUTF16toUTF8 bdAddressUTF8(aBdAddress);
const char* str = bdAddressUTF8.get();
for (int i = 0; i < 6; i++) {
aRetBdAddressType->address[i] = (uint8_t) strtoul(str, (char **)&str, 16);
@ -982,7 +983,7 @@ BluetoothServiceBluedroid::SetProperty(BluetoothObjectType aType,
const nsString propName = aValue.name();
bt_property_t prop;
bt_scan_mode_t scanMode;
nsString str;
nsCString str;
// For Bluedroid, it's necessary to check property name for SetProperty
if (propName.EqualsLiteral("Name")) {
@ -1000,8 +1001,8 @@ BluetoothServiceBluedroid::SetProperty(BluetoothObjectType aType,
prop.val = (void*)aValue.value().get_uint32_t();
} else if (aValue.value().type() == BluetoothValue::TnsString) {
// Set name
str = aValue.value().get_nsString();
const char* name = NS_ConvertUTF16toUTF8(str).get();
str = NS_ConvertUTF16toUTF8(aValue.value().get_nsString());
const char* name = str.get();
prop.val = (void*)name;
prop.len = strlen(name);
} else if (aValue.value().type() == BluetoothValue::Tbool) {