diff options
author | Henry Wilson <m3henry@googlemail.com> | 2019-02-20 19:27:10 +0000 |
---|---|---|
committer | PeterN <peter@fuzzle.org> | 2019-03-26 20:15:57 +0000 |
commit | 2bc2de9034d3b75a253b849cf7a703b1a503e200 (patch) | |
tree | 39f3a8e94a6f993f20dbbf027b6cdd684ab4ce4c /src/network/core | |
parent | e0c58bf5ee0f3f4d0563a04de315c09b37f74c6e (diff) | |
download | openttd-2bc2de9034d3b75a253b849cf7a703b1a503e200.tar.xz |
Codechange: Replaced SmallVector::Find() with std::find()
Diffstat (limited to 'src/network/core')
-rw-r--r-- | src/network/core/host.cpp | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/network/core/host.cpp b/src/network/core/host.cpp index 1ea5389d4..b1ed71e92 100644 --- a/src/network/core/host.cpp +++ b/src/network/core/host.cpp @@ -136,7 +136,7 @@ static void NetworkFindBroadcastIPsInternal(NetworkAddressList *broadcast) // Wi memcpy(&address, &ifo[j].iiAddress.Address, sizeof(sockaddr)); ((sockaddr_in*)&address)->sin_addr.s_addr = ifo[j].iiAddress.AddressIn.sin_addr.s_addr | ~ifo[j].iiNetmask.AddressIn.sin_addr.s_addr; NetworkAddress addr(address, sizeof(sockaddr)); - if (std::none_of(broadcast->begin(), broadcast->end(), [&addr](NetworkAddress const& elem) -> bool { return elem == addr; })) *broadcast->Append() = addr; + if (std::none_of(broadcast->begin(), broadcast->end(), [&addr](NetworkAddress const& elem) -> bool { return elem == addr; })) broadcast->push_back(addr); } free(ifo); |