Expand hosts (dns lookup) before calling create_connect

Also - while we are at it - lets simplify _connect_loop so it's
a bit easier to follow along (otherwise it's unclear what is
controlled by retry() and what's is iterated by _connect_loop,
_connect_attempt and _connect, respectively).