From: Stephan Bosch Date: Wed, 10 Oct 2018 22:49:44 +0000 (+0200) Subject: lmtp: proxy: Allocate recipients for the client transaction on the server recipient... X-Git-Tag: 2.3.9~1197 X-Git-Url: http://git.ipfire.org/?a=commitdiff_plain;h=9c54d83ba3c0de4fc249fcd9acae6979f07110d6;p=thirdparty%2Fdovecot%2Fcore.git lmtp: proxy: Allocate recipients for the client transaction on the server recipient pool. --- diff --git a/src/lmtp/lmtp-proxy.c b/src/lmtp/lmtp-proxy.c index aefee98ce9..fdfd2b1303 100644 --- a/src/lmtp/lmtp-proxy.c +++ b/src/lmtp/lmtp-proxy.c @@ -478,6 +478,7 @@ int lmtp_proxy_rcpt(struct client *client, const char *const *fields, *errstr, *orig_username = username; struct smtp_proxy_data proxy_data; struct smtp_address *user; + struct smtp_client_transaction_rcpt *relay_rcpt; pool_t auth_pool; int ret; @@ -578,9 +579,11 @@ int lmtp_proxy_rcpt(struct client *client, lmtp_proxy_rcpt_approved, lprcpt); rcpt->context = lprcpt; - smtp_client_transaction_add_rcpt(conn->lmtp_trans, - address, &rcpt->params, - lmtp_proxy_rcpt_cb, lmtp_proxy_data_cb, lprcpt); + relay_rcpt = smtp_client_transaction_add_pool_rcpt( + conn->lmtp_trans, rcpt->pool, address, &rcpt->params, + lmtp_proxy_rcpt_cb, lprcpt); + smtp_client_transaction_rcpt_set_data_callback( + relay_rcpt, lmtp_proxy_data_cb, lprcpt); return 1; }