Bug 1018355 - IPv6 tethering failure. r=chulee

This commit is contained in:
Vincent Chang 2014-06-05 11:49:38 +08:00
Родитель c4e5355de1
Коммит 58d3d3466b
1 изменённых файлов: 16 добавлений и 4 удалений

Просмотреть файл

@ -1556,10 +1556,16 @@ bool NetworkUtils::setWifiTethering(NetworkParams& aOptions)
getIFProperties(GET_CHAR(mExternalIfname), interfaceProperties);
if (strcmp(interfaceProperties.dns1, "")) {
aOptions.mDns1 = NS_ConvertUTF8toUTF16(interfaceProperties.dns1);
int type = getIpType(interfaceProperties.dns1);
if (type != AF_INET6) {
aOptions.mDns1 = NS_ConvertUTF8toUTF16(interfaceProperties.dns1);
}
}
if (strcmp(interfaceProperties.dns2, "")) {
aOptions.mDns2 = NS_ConvertUTF8toUTF16(interfaceProperties.dns2);
int type = getIpType(interfaceProperties.dns2);
if (type != AF_INET6) {
aOptions.mDns2 = NS_ConvertUTF8toUTF16(interfaceProperties.dns2);
}
}
dumpParams(aOptions, "WIFI");
@ -1582,10 +1588,16 @@ bool NetworkUtils::setUSBTethering(NetworkParams& aOptions)
getIFProperties(GET_CHAR(mExternalIfname), interfaceProperties);
if (strcmp(interfaceProperties.dns1, "")) {
aOptions.mDns1 = NS_ConvertUTF8toUTF16(interfaceProperties.dns1);
int type = getIpType(interfaceProperties.dns1);
if (type != AF_INET6) {
aOptions.mDns1 = NS_ConvertUTF8toUTF16(interfaceProperties.dns1);
}
}
if (strcmp(interfaceProperties.dns2, "")) {
aOptions.mDns2 = NS_ConvertUTF8toUTF16(interfaceProperties.dns2);
int type = getIpType(interfaceProperties.dns2);
if (type != AF_INET6) {
aOptions.mDns2 = NS_ConvertUTF8toUTF16(interfaceProperties.dns2);
}
}
dumpParams(aOptions, "USB");