]> git.ipfire.org Git - thirdparty/dovecot/core.git/commitdiff
lib-smtp: server: MAIL command: Implement smtp_server_cmd_mail_reply_success() for...
authorStephan Bosch <stephan.bosch@dovecot.fi>
Mon, 12 Mar 2018 00:01:46 +0000 (01:01 +0100)
committerStephan Bosch <stephan.bosch@dovecot.fi>
Mon, 29 Oct 2018 16:37:51 +0000 (17:37 +0100)
src/lib-smtp/smtp-server-cmd-mail.c
src/lib-smtp/smtp-server.h

index 35c86c01e230a1b3de8dad90bd827b2776a71267..a4eb4fcbb3da753d9105a9808cf390d1e5a39745 100644 (file)
@@ -193,7 +193,14 @@ void smtp_server_cmd_mail(struct smtp_server_cmd_ctx *cmd,
        }
        if (!smtp_server_command_is_replied(command)) {
                /* set generic MAIL success reply if none is provided */
-               smtp_server_reply(cmd, 250, "2.1.0", "OK");
+               smtp_server_cmd_mail_reply_success(cmd);
        }
        smtp_server_command_unref(&command);
 }
+
+void smtp_server_cmd_mail_reply_success(struct smtp_server_cmd_ctx *cmd)
+{
+       i_assert(cmd->cmd->reg->func == smtp_server_cmd_mail);
+
+       smtp_server_reply(cmd, 250, "2.1.0", "OK");
+}
index 034e9604228454d39bc0bbe669e878b753c1d605..05cc47832657ff3f2b9746bd8c0918e1189ba64f 100644 (file)
@@ -539,6 +539,10 @@ void smtp_server_cmd_auth_success(struct smtp_server_cmd_ctx *cmd,
        const char *username, const char *success_msg)
        ATTR_NULL(3);
 
+/* MAIL */
+
+void smtp_server_cmd_mail_reply_success(struct smtp_server_cmd_ctx *cmd);
+
 /* DATA */
 
 bool smtp_server_cmd_data_check_size(struct smtp_server_cmd_ctx *cmd);