Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(10)

Side by Side Diff: talk/app/webrtc/webrtcsession.cc

Issue 1299333003: Relanding Generate localhost candidate when no STUN/TURN and portallocator has the right flag spefi… (Closed) Base URL: https://chromium.googlesource.com/external/webrtc@master
Patch Set: Created 5 years, 4 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
« no previous file with comments | « talk/app/webrtc/peerconnectioninterface.h ('k') | webrtc/base/ipaddress.h » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 /* 1 /*
2 * libjingle 2 * libjingle
3 * Copyright 2012 Google Inc. 3 * Copyright 2012 Google Inc.
4 * 4 *
5 * Redistribution and use in source and binary forms, with or without 5 * Redistribution and use in source and binary forms, with or without
6 * modification, are permitted provided that the following conditions are met: 6 * modification, are permitted provided that the following conditions are met:
7 * 7 *
8 * 1. Redistributions of source code must retain the above copyright notice, 8 * 1. Redistributions of source code must retain the above copyright notice,
9 * this list of conditions and the following disclaimer. 9 * this list of conditions and the following disclaimer.
10 * 2. Redistributions in binary form must reproduce the above copyright notice, 10 * 2. Redistributions in binary form must reproduce the above copyright notice,
(...skipping 707 matching lines...) Expand 10 before | Expand all | Expand 10 after
718 dtls_enabled_)); 718 dtls_enabled_));
719 719
720 webrtc_session_desc_factory_->SignalIdentityReady.connect( 720 webrtc_session_desc_factory_->SignalIdentityReady.connect(
721 this, &WebRtcSession::OnIdentityReady); 721 this, &WebRtcSession::OnIdentityReady);
722 722
723 if (options.disable_encryption) { 723 if (options.disable_encryption) {
724 webrtc_session_desc_factory_->SetSdesPolicy(cricket::SEC_DISABLED); 724 webrtc_session_desc_factory_->SetSdesPolicy(cricket::SEC_DISABLED);
725 } 725 }
726 port_allocator()->set_candidate_filter( 726 port_allocator()->set_candidate_filter(
727 ConvertIceTransportTypeToCandidateFilter(rtc_configuration.type)); 727 ConvertIceTransportTypeToCandidateFilter(rtc_configuration.type));
728
729 if (rtc_configuration.enable_localhost_ice_candidate) {
730 port_allocator()->set_flags(
731 port_allocator()->flags() |
732 cricket::PORTALLOCATOR_ENABLE_LOCALHOST_CANDIDATE);
733 }
734
728 return true; 735 return true;
729 } 736 }
730 737
731 void WebRtcSession::Terminate() { 738 void WebRtcSession::Terminate() {
732 SetState(STATE_RECEIVEDTERMINATE); 739 SetState(STATE_RECEIVEDTERMINATE);
733 RemoveUnusedChannelsAndTransports(NULL); 740 RemoveUnusedChannelsAndTransports(NULL);
734 ASSERT(!voice_channel_); 741 ASSERT(!voice_channel_);
735 ASSERT(!video_channel_); 742 ASSERT(!video_channel_);
736 ASSERT(!data_channel_); 743 ASSERT(!data_channel_);
737 } 744 }
(...skipping 1306 matching lines...) Expand 10 before | Expand all | Expand 10 after
2044 2051
2045 if (!srtp_cipher.empty()) { 2052 if (!srtp_cipher.empty()) {
2046 metrics_observer_->AddHistogramSample(srtp_name, srtp_cipher); 2053 metrics_observer_->AddHistogramSample(srtp_name, srtp_cipher);
2047 } 2054 }
2048 if (!ssl_cipher.empty()) { 2055 if (!ssl_cipher.empty()) {
2049 metrics_observer_->AddHistogramSample(ssl_name, ssl_cipher); 2056 metrics_observer_->AddHistogramSample(ssl_name, ssl_cipher);
2050 } 2057 }
2051 } 2058 }
2052 2059
2053 } // namespace webrtc 2060 } // namespace webrtc
OLDNEW
« no previous file with comments | « talk/app/webrtc/peerconnectioninterface.h ('k') | webrtc/base/ipaddress.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698