]> git.ipfire.org Git - thirdparty/dovecot/core.git/commitdiff
lib-smtp: smtp-server-cmd-rset - Stop processing pipeline until RSET is complete.
authorStephan Bosch <stephan.bosch@open-xchange.com>
Mon, 9 Nov 2020 01:29:04 +0000 (02:29 +0100)
committerMartti Rannanjärvi <martti.rannanjarvi@open-xchange.com>
Fri, 21 Jan 2022 07:38:21 +0000 (09:38 +0200)
A subsequent MAIL command could get reset in the middle otherwise. Before, it
only blocked input until a reply was submitted, but the transaction isn't reset
until the RSET command is complete (just before actually sending the reply)
which can cause issues when the subsequent MAIL command is already being
processed.

src/lib-smtp/smtp-server-cmd-rset.c

index 6446a418ac4d212f65ca8ff94354c40362a0e3d3..b07478b8e7bbfb6144899b6888487b275f9f4d2e 100644 (file)
@@ -39,7 +39,7 @@ void smtp_server_cmd_rset(struct smtp_server_cmd_ctx *cmd,
                return;
        }
 
-       smtp_server_command_input_lock(cmd);
+       smtp_server_command_pipeline_block(cmd);
        smtp_server_command_add_hook(command, SMTP_SERVER_COMMAND_HOOK_COMPLETED,
                                     cmd_rset_completed, NULL);