diff options
Diffstat (limited to 'app/webrtc/peerconnection.cc')
-rw-r--r-- | app/webrtc/peerconnection.cc | 17 |
1 files changed, 9 insertions, 8 deletions
diff --git a/app/webrtc/peerconnection.cc b/app/webrtc/peerconnection.cc index 201269a..d939f98 100644 --- a/app/webrtc/peerconnection.cc +++ b/app/webrtc/peerconnection.cc @@ -39,6 +39,7 @@ #include "talk/session/media/channelmanager.h" #include "webrtc/base/logging.h" #include "webrtc/base/stringencode.h" +#include "webrtc/system_wrappers/interface/field_trial.h" namespace { @@ -353,10 +354,14 @@ bool PeerConnection::DoInitialize( cricket::PORTALLOCATOR_ENABLE_SHARED_UFRAG | cricket::PORTALLOCATOR_ENABLE_SHARED_SOCKET; bool value; + // If IPv6 flag was specified, we'll not override it by experiment. if (FindConstraint( - constraints, - MediaConstraintsInterface::kEnableIPv6, - &value, NULL) && value) { + constraints, MediaConstraintsInterface::kEnableIPv6, &value, NULL)) { + if (value) { + portallocator_flags |= cricket::PORTALLOCATOR_ENABLE_IPV6; + } + } else if (webrtc::field_trial::FindFullName("WebRTC-IPv6Default") == + "Enabled") { portallocator_flags |= cricket::PORTALLOCATOR_ENABLE_IPV6; } @@ -508,10 +513,6 @@ void PeerConnection::CreateOffer(CreateSessionDescriptionObserver* observer, return; } RTCOfferAnswerOptions options; - // Defaults to receiving audio and not receiving video. - options.offer_to_receive_audio = - RTCOfferAnswerOptions::kOfferToReceiveMediaTrue; - options.offer_to_receive_video = 0; bool value; size_t mandatory_constraints = 0; @@ -672,7 +673,7 @@ bool PeerConnection::UpdateIce(const RTCConfiguration& config) { } } } - return session_->UpdateIce(config.type); + return session_->SetIceTransports(config.type); } bool PeerConnection::AddIceCandidate( |