Fix error reporting for insane hostnames.

If you put some really silly values in (e.g. /) into hostnames then
the error message s super super cryptic.

This patch fixes that, so it's at least obvious what / where / why it's
failing if you use --trace --debug
Update to also be for destination
Merge pull request #155 from bobtfish/error_reporting_fix

Error reporting fix