merge Unix Domain Sockets support and other changes from develop

This commit is contained in:
Guenter Obiltschnig
2017-10-31 16:53:06 +01:00
parent d172273a75
commit a460bafa70
97 changed files with 2094 additions and 475 deletions

View File

@@ -78,6 +78,12 @@ void ServerSocket::bind(const SocketAddress& address, bool reuseAddress)
}
void ServerSocket::bind(const SocketAddress& address, bool reuseAddress, bool reusePort)
{
impl()->bind(address, reuseAddress, reusePort);
}
void ServerSocket::bind(Poco::UInt16 port, bool reuseAddress)
{
IPAddress wildcardAddr;
@@ -86,17 +92,47 @@ void ServerSocket::bind(Poco::UInt16 port, bool reuseAddress)
}
void ServerSocket::bind(Poco::UInt16 port, bool reuseAddress, bool reusePort)
{
IPAddress wildcardAddr;
SocketAddress address(wildcardAddr, port);
impl()->bind(address, reuseAddress, reusePort);
}
void ServerSocket::bind6(const SocketAddress& address, bool reuseAddress, bool ipV6Only)
{
impl()->bind6(address, reuseAddress, ipV6Only);
}
void ServerSocket::bind6(const SocketAddress& address, bool reuseAddress, bool reusePort, bool ipV6Only)
{
impl()->bind6(address, reuseAddress, reusePort, ipV6Only);
}
void ServerSocket::bind6(Poco::UInt16 port, bool reuseAddress, bool ipV6Only)
{
#if defined(POCO_HAVE_IPv6)
IPAddress wildcardAddr(IPAddress::IPv6);
SocketAddress address(wildcardAddr, port);
impl()->bind6(address, reuseAddress, ipV6Only);
#else
throw Poco::NotImplementedException("No IPv6 support available");
#endif // POCO_HAVE_IPv6
}
void ServerSocket::bind6(Poco::UInt16 port, bool reuseAddress, bool reusePort, bool ipV6Only)
{
#if defined(POCO_HAVE_IPv6)
IPAddress wildcardAddr(IPAddress::IPv6);
SocketAddress address(wildcardAddr, port);
impl()->bind6(address, reuseAddress, reusePort, ipV6Only);
#else
throw Poco::NotImplementedException("No IPv6 support available");
#endif // POCO_HAVE_IPv6
}