OLD | NEW |
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 660 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
671 dtls_enabled_)); | 671 dtls_enabled_)); |
672 | 672 |
673 webrtc_session_desc_factory_->SignalIdentityReady.connect( | 673 webrtc_session_desc_factory_->SignalIdentityReady.connect( |
674 this, &WebRtcSession::OnIdentityReady); | 674 this, &WebRtcSession::OnIdentityReady); |
675 | 675 |
676 if (options.disable_encryption) { | 676 if (options.disable_encryption) { |
677 webrtc_session_desc_factory_->SetSdesPolicy(cricket::SEC_DISABLED); | 677 webrtc_session_desc_factory_->SetSdesPolicy(cricket::SEC_DISABLED); |
678 } | 678 } |
679 port_allocator()->set_candidate_filter( | 679 port_allocator()->set_candidate_filter( |
680 ConvertIceTransportTypeToCandidateFilter(rtc_configuration.type)); | 680 ConvertIceTransportTypeToCandidateFilter(rtc_configuration.type)); |
| 681 |
| 682 if (rtc_configuration.enable_localhost_ice_candidate) { |
| 683 port_allocator()->set_flags( |
| 684 port_allocator()->flags() | |
| 685 cricket::PORTALLOCATOR_ENABLE_LOCALHOST_CANDIDATE); |
| 686 } |
| 687 |
681 return true; | 688 return true; |
682 } | 689 } |
683 | 690 |
684 void WebRtcSession::Terminate() { | 691 void WebRtcSession::Terminate() { |
685 SetState(STATE_RECEIVEDTERMINATE); | 692 SetState(STATE_RECEIVEDTERMINATE); |
686 RemoveUnusedChannelsAndTransports(NULL); | 693 RemoveUnusedChannelsAndTransports(NULL); |
687 ASSERT(!voice_channel_); | 694 ASSERT(!voice_channel_); |
688 ASSERT(!video_channel_); | 695 ASSERT(!video_channel_); |
689 ASSERT(!data_channel_); | 696 ASSERT(!data_channel_); |
690 } | 697 } |
(...skipping 1269 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1960 | 1967 |
1961 if (!srtp_cipher.empty()) { | 1968 if (!srtp_cipher.empty()) { |
1962 metrics_observer_->AddHistogramSample(srtp_name, srtp_cipher); | 1969 metrics_observer_->AddHistogramSample(srtp_name, srtp_cipher); |
1963 } | 1970 } |
1964 if (!ssl_cipher.empty()) { | 1971 if (!ssl_cipher.empty()) { |
1965 metrics_observer_->AddHistogramSample(ssl_name, ssl_cipher); | 1972 metrics_observer_->AddHistogramSample(ssl_name, ssl_cipher); |
1966 } | 1973 } |
1967 } | 1974 } |
1968 | 1975 |
1969 } // namespace webrtc | 1976 } // namespace webrtc |
OLD | NEW |