]> git.ipfire.org Git - thirdparty/dovecot/core.git/commitdiff
submission: Split the VRFY command into a generic part and a part related to relaying...
authorStephan Bosch <stephan.bosch@dovecot.fi>
Wed, 29 Aug 2018 20:37:27 +0000 (22:37 +0200)
committerAki Tuomi <aki.tuomi@open-xchange.com>
Tue, 9 Oct 2018 06:41:17 +0000 (06:41 +0000)
src/submission/cmd-vrfy.c
src/submission/submission-commands.h

index f4bd4b797543fa34472311c73cf524d1b9e5bfc6..8486bc3dd03f956816b1ed0526d1821f2a363264 100644 (file)
@@ -42,10 +42,9 @@ static void cmd_vrfy_proxy_cb(const struct smtp_reply *proxy_reply,
        smtp_server_reply_forward(cmd, &reply);
 }
 
-int cmd_vrfy(void *conn_ctx, struct smtp_server_cmd_ctx *cmd,
-            const char *param)
+int cmd_vrfy_relay(struct client *client, struct smtp_server_cmd_ctx *cmd,
+                  const char *param)
 {
-       struct client *client = conn_ctx;
        struct cmd_vrfy_context *vrfy_cmd;
 
        vrfy_cmd = p_new(cmd->pool, struct cmd_vrfy_context, 1);
@@ -56,3 +55,11 @@ int cmd_vrfy(void *conn_ctx, struct smtp_server_cmd_ctx *cmd,
                client->proxy_conn, 0, param, cmd_vrfy_proxy_cb, vrfy_cmd);
        return 0;
 }
+
+int cmd_vrfy(void *conn_ctx, struct smtp_server_cmd_ctx *cmd,
+            const char *param)
+{
+       struct client *client = conn_ctx;
+
+       return cmd_vrfy_relay(client, cmd, param);
+}
index 85d4384e1258416c8725be58f742a2786ed9e1f1..640198b21ca4300ee604ee108962dd5e2a9fa299 100644 (file)
@@ -14,6 +14,8 @@ int cmd_rset_relay(struct client *client, struct smtp_server_cmd_ctx *cmd);
 int cmd_data_relay(struct client *client, struct smtp_server_cmd_ctx *cmd,
                   struct smtp_server_transaction *trans,
                   struct istream *data_input);
+int cmd_vrfy_relay(struct client *client, struct smtp_server_cmd_ctx *cmd,
+                  const char *param);
 
 void submission_helo_reply_submit(struct smtp_server_cmd_ctx *cmd,
                                  struct smtp_server_cmd_helo *data);