Commit fe37f24b authored by aligungr's avatar aligungr

IPv6 support

parent bdf07780
...@@ -41,14 +41,14 @@ void UdpServer::Send(const InetAddress &address, const uint8_t *buffer, size_t b ...@@ -41,14 +41,14 @@ void UdpServer::Send(const InetAddress &address, const uint8_t *buffer, size_t b
for (const Socket &s : sockets) for (const Socket &s : sockets)
{ {
if (s.getIpVersion() == version) if (s.hasFd() && s.getIpVersion() == version)
{ {
s.send(address, buffer, bufferSize); s.send(address, buffer, bufferSize);
return; return;
} }
} }
throw std::runtime_error{"UdpServer::Send failure: No socket found"}; throw std::runtime_error{"UdpServer::Send failure: No IP socket found"};
} }
UdpServer::~UdpServer() UdpServer::~UdpServer()
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment