There's getaddrinfo() for blocking host resolution, but is there a non blocking method?
getaddrinfo()