Bug 1189030 - Add pref "media.peerconnection.ice.relay_only" (default=false). r=jesup

--HG--
extra : transplant_source : 1%D5%AC%F1%FA%EB%0B%C2%90%8A%83DtVz-L%2C%CC%14
This commit is contained in:
Jan-Ivar Bruaroey 2015-07-30 10:48:27 -04:00
Родитель 404dd1ef88
Коммит c84f148731
2 изменённых файлов: 7 добавлений и 0 удалений

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

@ -323,6 +323,12 @@ RTCPeerConnection.prototype = {
__init: function(rtcConfig) {
this._winID = this._win.QueryInterface(Ci.nsIInterfaceRequestor)
.getInterface(Ci.nsIDOMWindowUtils).currentInnerWindowID;
// TODO: Update this code once we support pc.setConfiguration, to track
// setting from content independently from pref (Bug 1181768).
if (rtcConfig.iceTransportPolicy == "all" &&
Services.prefs.getBoolPref("media.peerconnection.ice.relay_only")) {
rtcConfig.iceTransportPolicy = "relay";
}
if (!rtcConfig.iceServers ||
!Services.prefs.getBoolPref("media.peerconnection.use_document_iceservers")) {
try {

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

@ -398,6 +398,7 @@ pref("media.peerconnection.default_iceservers", "[]");
pref("media.peerconnection.ice.loopback", false); // Set only for testing in offline environments.
pref("media.peerconnection.ice.tcp", false);
pref("media.peerconnection.ice.link_local", false); // Set only for testing IPV6 in networks that don't assign IPV6 addresses
pref("media.peerconnection.ice.relay_only", false); // Limit candidates to TURN
pref("media.peerconnection.use_document_iceservers", true);
pref("media.peerconnection.identity.enabled", true);
pref("media.peerconnection.identity.timeout", 10000);