From 420dc25a312689198499a7d1a917f54da24e506f Mon Sep 17 00:00:00 2001 From: Stephan Bosch Date: Mon, 18 Sep 2017 23:48:51 +0200 Subject: [PATCH] lmtp: Moved client_rcpt_fail_all() from commands.c to lmtp-local.c. --- src/lmtp/commands.c | 10 ---------- src/lmtp/lmtp-local.c | 10 ++++++++++ src/lmtp/lmtp-local.h | 2 ++ 3 files changed, 12 insertions(+), 10 deletions(-) diff --git a/src/lmtp/commands.c b/src/lmtp/commands.c index e0cd50722b..adc0d3875f 100644 --- a/src/lmtp/commands.c +++ b/src/lmtp/commands.c @@ -545,16 +545,6 @@ int cmd_noop(struct client *client, const char *args ATTR_UNUSED) return 0; } -static void client_rcpt_fail_all(struct client *client) -{ - struct mail_recipient *const *rcptp; - - array_foreach(&client->state.rcpt_to, rcptp) { - client_send_line(client, ERRSTR_TEMP_MAILBOX_FAIL, - smtp_address_encode((*rcptp)->address)); - } -} - static struct istream *client_get_input(struct client *client) { struct client_state *state = &client->state; diff --git a/src/lmtp/lmtp-local.c b/src/lmtp/lmtp-local.c index 97462e2912..2d5156989f 100644 --- a/src/lmtp/lmtp-local.c +++ b/src/lmtp/lmtp-local.c @@ -50,6 +50,16 @@ client_send_line_overquota(struct client *client, smtp_address_encode(rcpt->address), error); } +void client_rcpt_fail_all(struct client *client) +{ + struct mail_recipient *const *rcptp; + + array_foreach(&client->state.rcpt_to, rcptp) { + client_send_line(client, ERRSTR_TEMP_MAILBOX_FAIL, + smtp_address_encode((*rcptp)->address)); + } +} + static int lmtp_rcpt_to_is_over_quota(struct client *client, const struct mail_recipient *rcpt) diff --git a/src/lmtp/lmtp-local.h b/src/lmtp/lmtp-local.h index b4752497db..245d55f19f 100644 --- a/src/lmtp/lmtp-local.h +++ b/src/lmtp/lmtp-local.h @@ -7,6 +7,8 @@ struct mail_deliver_session; void client_rcpt_anvil_disconnect(const struct mail_recipient *rcpt); +void client_rcpt_fail_all(struct client *client); + bool cmd_rcpt_finish(struct client *client, struct mail_recipient *rcpt); void rcpt_anvil_lookup_callback(const char *reply, void *context); -- 2.47.3