| 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 212 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 223 bool started() { return start_count_ > 0; } | 223 bool started() { return start_count_ > 0; } |
| 224 | 224 |
| 225 // Sets the network ignore list, which is empty by default. Any network on the | 225 // Sets the network ignore list, which is empty by default. Any network on the |
| 226 // ignore list will be filtered from network enumeration results. | 226 // ignore list will be filtered from network enumeration results. |
| 227 void set_network_ignore_list(const std::vector<std::string>& list) { | 227 void set_network_ignore_list(const std::vector<std::string>& list) { |
| 228 network_ignore_list_ = list; | 228 network_ignore_list_ = list; |
| 229 } | 229 } |
| 230 | 230 |
| 231 #if defined(WEBRTC_LINUX) | 231 #if defined(WEBRTC_LINUX) |
| 232 // Sets the flag for ignoring non-default routes. | 232 // Sets the flag for ignoring non-default routes. |
| 233 // Defaults to false. |
| 233 void set_ignore_non_default_routes(bool value) { | 234 void set_ignore_non_default_routes(bool value) { |
| 234 ignore_non_default_routes_ = true; | 235 ignore_non_default_routes_ = value; |
| 235 } | 236 } |
| 236 #endif | 237 #endif |
| 237 | 238 |
| 238 protected: | 239 protected: |
| 239 #if defined(WEBRTC_POSIX) | 240 #if defined(WEBRTC_POSIX) |
| 240 // Separated from CreateNetworks for tests. | 241 // Separated from CreateNetworks for tests. |
| 241 void ConvertIfAddrs(ifaddrs* interfaces, | 242 void ConvertIfAddrs(ifaddrs* interfaces, |
| 242 IfAddrsConverter* converter, | 243 IfAddrsConverter* converter, |
| 243 bool include_ignored, | 244 bool include_ignored, |
| 244 NetworkList* networks) const; | 245 NetworkList* networks) const; |
| (...skipping 180 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 425 int preference_; | 426 int preference_; |
| 426 bool active_ = true; | 427 bool active_ = true; |
| 427 uint16_t id_ = 0; | 428 uint16_t id_ = 0; |
| 428 | 429 |
| 429 friend class NetworkManager; | 430 friend class NetworkManager; |
| 430 }; | 431 }; |
| 431 | 432 |
| 432 } // namespace rtc | 433 } // namespace rtc |
| 433 | 434 |
| 434 #endif // WEBRTC_RTC_BASE_NETWORK_H_ | 435 #endif // WEBRTC_RTC_BASE_NETWORK_H_ |
| OLD | NEW |