From 9e0ed81fc2a821e60dd3235c4e5598ab45cfcc1e Mon Sep 17 00:00:00 2001 From: Jeremy Harris Date: Sun, 8 Oct 2017 18:56:13 +0100 Subject: Logging: show when input from truncated for logging "next input sent too soon" --- src/src/smtp_in.c | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) (limited to 'src') diff --git a/src/src/smtp_in.c b/src/src/smtp_in.c index 0f8d5599b..9847c86c7 100644 --- a/src/src/smtp_in.c +++ b/src/src/smtp_in.c @@ -565,11 +565,12 @@ for(;;) incomplete_transaction_log(US"sync failure"); log_write(0, LOG_MAIN|LOG_REJECT, "SMTP protocol synchronization error " "(next input sent too soon: pipelining was not advertised): " - "rejected \"%s\" %s next input=\"%s\"", + "rejected \"%s\" %s next input=\"%s\"%s", smtp_cmd_buffer, host_and_ident(TRUE), - string_printing(string_copyn(smtp_inptr, n))); - (void) synprot_error(L_smtp_protocol_error, 554, NULL, - US"SMTP synchronization error"); + string_printing(string_copyn(smtp_inptr, n)), + smtp_inend - smtp_inptr > n ? "..." : ""); + (void) synprot_error(L_smtp_protocol_error, 554, NULL, + US"SMTP synchronization error"); goto repeat_until_rset; } -- cgit v1.2.3