Portable Modern Network Programming (cont.) server side make all sockets provided by getaddrinfo(3) ready for accepting set IPV6_V6ONLY if available (#ifdef) don't consider the error of setsockopt(2) as fatal don't consider the error of bind(2) as fatal (*) Don't forget IPv4-mapped addresses *: if you're okay not to support older linux, it is okay to consider it as fatal