* Get the addresses to bind to. * @param addresses the list to write to. * @param port the port to bind to. */
| 717 | * @param port the port to bind to. |
| 718 | */ |
| 719 | void GetBindAddresses(NetworkAddressList *addresses, uint16_t port) |
| 720 | { |
| 721 | for (const auto &iter : _network_bind_list) { |
| 722 | addresses->emplace_back(iter, port); |
| 723 | } |
| 724 | |
| 725 | /* No address, so bind to everything. */ |
| 726 | if (addresses->empty()) { |
| 727 | addresses->emplace_back("", port); |
| 728 | } |
| 729 | } |
| 730 | |
| 731 | /* Generates the list of manually added hosts from NetworkGame and |
| 732 | * dumps them into the array _network_host_list. This array is needed |
no test coverage detected