[exim-cvs] Log: more info in transport "line too long" error…

Αρχική Σελίδα
Delete this message
Reply to this message
Συντάκτης: Exim Git Commits Mailing List
Ημερομηνία:  
Προς: exim-cvs
Αντικείμενο: [exim-cvs] Log: more info in transport "line too long" error message. Bug 2871
Gitweb: https://git.exim.org/exim.git/commitdiff/77cbc05dbee9776fc32affbb0d8b7e9440444aaa
Commit:     77cbc05dbee9776fc32affbb0d8b7e9440444aaa
Parent:     a449ff8ca50e6df5faee2f1e83e1198c27738dfc
Author:     Arkadiusz Miśkiewicz <arekm@???>
AuthorDate: Sun Sep 15 15:40:03 2024 +0100
Committer:  Jeremy Harris <jgh146exb@???>
CommitDate: Sun Sep 15 15:40:03 2024 +0100

    Log: more info in transport "line too long" error message.  Bug 2871
---
 src/src/transports/smtp.c | 5 ++++-
 test/log/0589             | 2 +-
 2 files changed, 5 insertions(+), 2 deletions(-)

diff --git a/src/src/transports/smtp.c b/src/src/transports/smtp.c
index 594b42e1f..79bacfc31 100644
--- a/src/src/transports/smtp.c
+++ b/src/src/transports/smtp.c
@@ -5237,7 +5237,10 @@ if (max_received_linelength > ob->message_linelength_limit)
       addr->transport_return = PENDING_DEFER;
 
   set_errno_nohost(addrlist, ERRNO_SMTPFORMAT,
-    US"message has lines too long for transport", FAIL, TRUE, &now);
+    string_sprintf("message has lines too long for transport "
+            "(received %d, limit %d)",
+            max_received_linelength, ob->message_linelength_limit),
+          FAIL, TRUE, &now);
   goto END_TRANSPORT;
   }
 
diff --git a/test/log/0589 b/test/log/0589
index 6742764ca..81f7ff39f 100644
--- a/test/log/0589
+++ b/test/log/0589
@@ -8,7 +8,7 @@
 2017-07-30 18:51:05.712 10HmaZ-000000005vi-0000 Completed
 2017-07-30 18:51:05.712 10HmaX-000000005vi-0000 => good@??? F=<CALLER@???> R=smtp_try T=send_to_server H=ip4.ip4.ip4.ip4 [ip4.ip4.ip4.ip4] C="250 OK id=10HmaZ-000000005vi-0000"
 2017-07-30 18:51:05.712 10HmaX-000000005vi-0000 Completed
-2017-07-30 18:51:05.712 10HmaY-000000005vi-0000 ** bad@??? F=<CALLER@???> R=smtp_try T=send_to_server: message has lines too long for transport
+2017-07-30 18:51:05.712 10HmaY-000000005vi-0000 ** bad@??? F=<CALLER@???> R=smtp_try T=send_to_server: message has lines too long for transport (received 999, limit 998)
 2017-07-30 18:51:05.712 10HmbA-000000005vi-0000 <= <> R=10HmaY-000000005vi-0000 U=EXIMUSER P=local S=sss for CALLER@???
 2017-07-30 18:51:05.712 10HmbA-000000005vi-0000 => :blackhole: <CALLER@???> R=rx_dump
 2017-07-30 18:51:05.712 10HmbA-000000005vi-0000 Completed


--
## subscription configuration (requires account):
## https://lists.exim.org/mailman3/postorius/lists/exim-cvs.lists.exim.org/
## unsubscribe (doesn't require an account):
## exim-cvs-unsubscribe@???
## Exim details at http://www.exim.org/
## Please use the Wiki with this list - http://wiki.exim.org/