Subsequent changes remove the guarantee that the connection is setup successfuly
(to gain EHLO capabilities) before commands are submitted. This means that the
callbacks from commands can thereafter return connection setup errors as well.
case SMTP_CLIENT_COMMAND_ERROR_HOST_LOOKUP_FAILED:
case SMTP_CLIENT_COMMAND_ERROR_CONNECT_FAILED:
case SMTP_CLIENT_COMMAND_ERROR_AUTH_FAILED:
- i_unreached();
+ client_destroy(client,
+ "4.4.0", "Failed to connect to relay server");
return FALSE;
case SMTP_CLIENT_COMMAND_ERROR_CONNECTION_CLOSED:
case SMTP_CLIENT_COMMAND_ERROR_CONNECTION_LOST: