Properly handle SFTP connection errors.