Connection: Move socket creation out of setup

Once we support IPv6, we won’t be able to create a socket until we
know which address family to use.

Signed-off-by: Anders Kaseorg <andersk@mit.edu>
Connection: Support IPv6 addresses

Signed-off-by: Anders Kaseorg <andersk@mit.edu>
scripts/mosh: Let IO::Socket resolve the hostname

Signed-off-by: Anders Kaseorg <andersk@mit.edu>
scripts/mosh: Add -6 option to connect with IPv6

Signed-off-by: Anders Kaseorg <andersk@mit.edu>
AF_INET