From 99ea1c866060c4ca655973128f06d41c8efe9a44 Mon Sep 17 00:00:00 2001 From: Philip Hazel Date: Tue, 7 Nov 2006 11:28:05 +0000 Subject: [PATCH] Return remote errors for LMTP over pipe (so now it's the same as LMTP over TCP/IP). --- doc/doc-txt/ChangeLog | 7 ++++++- src/src/transports/lmtp.c | 4 +++- test/mail/5101.copied | 2 ++ 3 files changed, 11 insertions(+), 2 deletions(-) diff --git a/doc/doc-txt/ChangeLog b/doc/doc-txt/ChangeLog index 99e28d07a..53b82096f 100644 --- a/doc/doc-txt/ChangeLog +++ b/doc/doc-txt/ChangeLog @@ -1,4 +1,4 @@ -$Cambridge: exim/doc/doc-txt/ChangeLog,v 1.425 2006/11/06 15:50:12 ph10 Exp $ +$Cambridge: exim/doc/doc-txt/ChangeLog,v 1.426 2006/11/07 11:28:05 ph10 Exp $ Change log file for Exim from version 4.21 ------------------------------------------- @@ -247,6 +247,11 @@ PH/36 After a 4xx response to a RCPT error, that address was delayed (in queue can be overridden by setting address_retry_include_sender=false in the smtp transport. +PH/37 For LMTP over TCP/IP (the smtp transport), error responses from the + remote server are returned as part of bounce messages. This was not + happening for LMTP over a pipe (the lmtp transport), but now it is the + same for both kinds of LMTP. + Exim version 4.63 ----------------- diff --git a/src/src/transports/lmtp.c b/src/src/transports/lmtp.c index 969e45d60..59b967a13 100644 --- a/src/src/transports/lmtp.c +++ b/src/src/transports/lmtp.c @@ -1,4 +1,4 @@ -/* $Cambridge: exim/src/src/transports/lmtp.c,v 1.8 2006/03/09 15:10:16 ph10 Exp $ */ +/* $Cambridge: exim/src/src/transports/lmtp.c,v 1.9 2006/11/07 11:28:05 ph10 Exp $ */ /************************************************* * Exim - an Internet mail transport agent * @@ -606,6 +606,7 @@ for (addr = addrlist; addr != NULL; addr = addr->next) if (errno != 0 || buffer[0] == 0) goto RESPONSE_FAILED; addr->message = string_sprintf("LMTP error after %s: %s", big_buffer, string_printing(buffer)); + setflag(addr, af_pass_message); /* Allow message to go to user */ if (buffer[0] == '5') addr->transport_return = FAIL; else { addr->basic_errno = ERRNO_RCPT4XX; @@ -697,6 +698,7 @@ if (send_data) addr->message = string_sprintf("LMTP error after %s: %s", big_buffer, string_printing(buffer)); addr->transport_return = (buffer[0] == '5')? FAIL : DEFER; + setflag(addr, af_pass_message); /* Allow message to go to user */ } } } diff --git a/test/mail/5101.copied b/test/mail/5101.copied index e76adad79..4704c33ff 100644 --- a/test/mail/5101.copied +++ b/test/mail/5101.copied @@ -34,6 +34,7 @@ A message that you sent could not be delivered to one or more of its recipients. This is a permanent error. The following address(es) failed: jack@myhost.test.ex + LMTP error after end of data: 550 Number 2 fails ------ This is a copy of the message, including all the headers. ------ @@ -69,6 +70,7 @@ A message that you sent could not be delivered to one or more of its recipients. This is a permanent error. The following address(es) failed: jack@myhost.test.ex + LMTP error after end of data: 550 Number 2 fails ------ This is a copy of the message, including all the headers. ------ -- 2.25.1