client: improve error message on connect failures.