Chromium Code Reviews

Unified Diff: webrtc/p2p/client/basicportallocator.cc

Issue 1308753003: Revert "Reland "Remove GICE (gone forever!) and PORTALLOCATOR_ENABLE_SHARED_UFRAG (enabled forever)… (Closed) Base URL: https://chromium.googlesource.com/external/webrtc.git@master
Patch Set: Created 5 years, 4 months ago
Use n/p to move between diff chunks; N/P to move between comments.
Jump to:
View side-by-side diff with in-line comments
Index: webrtc/p2p/client/basicportallocator.cc
diff --git a/webrtc/p2p/client/basicportallocator.cc b/webrtc/p2p/client/basicportallocator.cc
index f90c52164ccda049a4a873698f6c857b3524726b..e52c5847d4bfd066c4293aea0aab8ef19b46baf3 100644
--- a/webrtc/p2p/client/basicportallocator.cc
+++ b/webrtc/p2p/client/basicportallocator.cc
@@ -692,6 +692,14 @@ AllocationSequence::AllocationSequence(BasicPortAllocatorSession* session,
}
bool AllocationSequence::Init() {
+ if (IsFlagSet(PORTALLOCATOR_ENABLE_SHARED_SOCKET) &&
+ !IsFlagSet(PORTALLOCATOR_ENABLE_SHARED_UFRAG)) {
+ LOG(LS_ERROR) << "Shared socket option can't be set without "
+ << "shared ufrag.";
+ ASSERT(false);
+ return false;
+ }
+
if (IsFlagSet(PORTALLOCATOR_ENABLE_SHARED_SOCKET)) {
udp_socket_.reset(session_->socket_factory()->CreateUdpSocket(
rtc::SocketAddress(ip_, 0), session_->allocator()->min_port(),

Powered by Google App Engine