| OLD | NEW |
| 1 /* | 1 /* |
| 2 * Copyright 2004 The WebRTC Project Authors. All rights reserved. | 2 * Copyright 2004 The WebRTC Project Authors. All rights reserved. |
| 3 * | 3 * |
| 4 * Use of this source code is governed by a BSD-style license | 4 * Use of this source code is governed by a BSD-style license |
| 5 * that can be found in the LICENSE file in the root of the source | 5 * that can be found in the LICENSE file in the root of the source |
| 6 * tree. An additional intellectual property rights grant can be found | 6 * tree. An additional intellectual property rights grant can be found |
| 7 * in the file PATENTS. All contributing project authors may | 7 * in the file PATENTS. All contributing project authors may |
| 8 * be found in the AUTHORS file in the root of the source tree. | 8 * be found in the AUTHORS file in the root of the source tree. |
| 9 */ | 9 */ |
| 10 | 10 |
| (...skipping 592 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 603 // No relay ports specified in this config. | 603 // No relay ports specified in this config. |
| 604 sequence_flags |= PORTALLOCATOR_DISABLE_RELAY; | 604 sequence_flags |= PORTALLOCATOR_DISABLE_RELAY; |
| 605 } | 605 } |
| 606 | 606 |
| 607 if (!(sequence_flags & PORTALLOCATOR_ENABLE_IPV6) && | 607 if (!(sequence_flags & PORTALLOCATOR_ENABLE_IPV6) && |
| 608 networks[i]->GetBestIP().family() == AF_INET6) { | 608 networks[i]->GetBestIP().family() == AF_INET6) { |
| 609 // Skip IPv6 networks unless the flag's been set. | 609 // Skip IPv6 networks unless the flag's been set. |
| 610 continue; | 610 continue; |
| 611 } | 611 } |
| 612 | 612 |
| 613 if (!(sequence_flags & PORTALLOCATOR_ENABLE_IPV6_ON_WIFI) && |
| 614 networks[i]->GetBestIP().family() == AF_INET6 && |
| 615 networks[i]->type() == rtc::ADAPTER_TYPE_WIFI) { |
| 616 // Skip IPv6 Wi-Fi networks unless the flag's been set. |
| 617 continue; |
| 618 } |
| 619 |
| 613 // Disable phases that would only create ports equivalent to | 620 // Disable phases that would only create ports equivalent to |
| 614 // ones that we have already made. | 621 // ones that we have already made. |
| 615 DisableEquivalentPhases(networks[i], config, &sequence_flags); | 622 DisableEquivalentPhases(networks[i], config, &sequence_flags); |
| 616 | 623 |
| 617 if ((sequence_flags & DISABLE_ALL_PHASES) == DISABLE_ALL_PHASES) { | 624 if ((sequence_flags & DISABLE_ALL_PHASES) == DISABLE_ALL_PHASES) { |
| 618 // New AllocationSequence would have nothing to do, so don't make it. | 625 // New AllocationSequence would have nothing to do, so don't make it. |
| 619 continue; | 626 continue; |
| 620 } | 627 } |
| 621 | 628 |
| 622 AllocationSequence* sequence = | 629 AllocationSequence* sequence = |
| (...skipping 892 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1515 ServerAddresses servers; | 1522 ServerAddresses servers; |
| 1516 for (size_t i = 0; i < relays.size(); ++i) { | 1523 for (size_t i = 0; i < relays.size(); ++i) { |
| 1517 if (relays[i].type == turn_type && SupportsProtocol(relays[i], type)) { | 1524 if (relays[i].type == turn_type && SupportsProtocol(relays[i], type)) { |
| 1518 servers.insert(relays[i].ports.front().address); | 1525 servers.insert(relays[i].ports.front().address); |
| 1519 } | 1526 } |
| 1520 } | 1527 } |
| 1521 return servers; | 1528 return servers; |
| 1522 } | 1529 } |
| 1523 | 1530 |
| 1524 } // namespace cricket | 1531 } // namespace cricket |
| OLD | NEW |