From: Philip Hazel Date: Tue, 17 May 2005 11:20:32 +0000 (+0000) Subject: Output the warning log line about deferring conditions in "warn" X-Git-Tag: exim-4_52~94 X-Git-Url: https://vcs.fsf.org/?a=commitdiff_plain;h=9c7a242c6007e9854d3332777c0ca131da51c775;p=exim.git Output the warning log line about deferring conditions in "warn" statements every time, not just once per message. --- diff --git a/doc/doc-txt/ChangeLog b/doc/doc-txt/ChangeLog index 3848f78c7..9f2f6c4be 100644 --- a/doc/doc-txt/ChangeLog +++ b/doc/doc-txt/ChangeLog @@ -1,4 +1,4 @@ -$Cambridge: exim/doc/doc-txt/ChangeLog,v 1.137 2005/05/17 09:53:34 ph10 Exp $ +$Cambridge: exim/doc/doc-txt/ChangeLog,v 1.138 2005/05/17 11:20:32 ph10 Exp $ Change log file for Exim from version 4.21 ------------------------------------------- @@ -19,6 +19,11 @@ TK/01 Fix poll() being unavailable on Mac OSX 10.2. PH/02 Reduce the amount of output that "make" produces by default. Full output can still be requested. +PH/03 The warning log line about a condition test deferring for a "warn" verb + was being output only once per connection, rather than after each + occurrence (because it was using the same function as for successful + "warn" verbs). This seems wrong, so I have changed it. + Exim version 4.51 ----------------- diff --git a/src/src/acl.c b/src/src/acl.c index 9d4a7789f..3f5015b85 100644 --- a/src/src/acl.c +++ b/src/src/acl.c @@ -1,4 +1,4 @@ -/* $Cambridge: exim/src/src/acl.c,v 1.30 2005/05/11 09:26:55 ph10 Exp $ */ +/* $Cambridge: exim/src/src/acl.c,v 1.31 2005/05/17 11:20:32 ph10 Exp $ */ /************************************************* * Exim - an Internet mail transport agent * @@ -788,8 +788,8 @@ if (log_message != NULL && log_message != user_message) strcmpic(log_message, US"sender verify failed") == 0) text = string_sprintf("%s: %s", text, sender_verified_failed->message); - /* Search previously logged warnings. They are kept in malloc store so they - can be freed at the start of a new message. */ + /* Search previously logged warnings. They are kept in malloc + store so they can be freed at the start of a new message. */ for (logged = acl_warn_logged; logged != NULL; logged = logged->next) if (Ustrcmp(logged->text, text) == 0) break; @@ -2950,9 +2950,10 @@ while (acl != NULL) if (cond == OK) acl_warn(where, *user_msgptr, *log_msgptr); else if (cond == DEFER) - acl_warn(where, NULL, string_sprintf("ACL \"warn\" statement skipped: " - "condition test deferred: %s", - (*log_msgptr == NULL)? US"" : *log_msgptr)); + log_write(0, LOG_MAIN, "%s Warning: ACL \"warn\" statement skipped: " + "condition test deferred%s%s", host_and_ident(TRUE), + (*log_msgptr == NULL)? US"" : US": ", + (*log_msgptr == NULL)? US"" : *log_msgptr); *log_msgptr = *user_msgptr = NULL; /* In case implicit DENY follows */ break;