From: Stephan Bosch Date: Sat, 29 Sep 2018 18:39:28 +0000 (+0200) Subject: lib-smtp: client: Add smtp_client_command_drop_callback(). X-Git-Tag: 2.3.9~1273 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=24f9503896b2947d445fe8244866767d3a7cd796;p=thirdparty%2Fdovecot%2Fcore.git lib-smtp: client: Add smtp_client_command_drop_callback(). --- diff --git a/src/lib-smtp/smtp-client-command.c b/src/lib-smtp/smtp-client-command.c index de77a85c71..346502ed15 100644 --- a/src/lib-smtp/smtp-client-command.c +++ b/src/lib-smtp/smtp-client-command.c @@ -275,6 +275,12 @@ void smtp_client_command_abort(struct smtp_client_command **_cmd) smtp_client_connection_trigger_output(conn); } +void smtp_client_command_drop_callback(struct smtp_client_command *cmd) +{ + cmd->callback = NULL; + cmd->context = NULL; +} + void smtp_client_command_fail_reply(struct smtp_client_command **_cmd, const struct smtp_reply *reply) { diff --git a/src/lib-smtp/smtp-client-private.h b/src/lib-smtp/smtp-client-private.h index 4f9c02dc26..13f52ccb41 100644 --- a/src/lib-smtp/smtp-client-private.h +++ b/src/lib-smtp/smtp-client-private.h @@ -196,6 +196,8 @@ int smtp_client_command_send_more(struct smtp_client_connection *conn); int smtp_client_command_input_reply(struct smtp_client_command *cmd, const struct smtp_reply *reply); +void smtp_client_command_drop_callback(struct smtp_client_command *cmd); + void smtp_client_command_fail(struct smtp_client_command **_cmd, unsigned int status, const char *error); void smtp_client_command_fail_reply(struct smtp_client_command **_cmd,