[exim-cvs] Include address declared malformed, in error mess…

Αρχική Σελίδα
Delete this message
Reply to this message
Συντάκτης: Exim Git Commits Mailing List
Ημερομηνία:  
Προς: exim-cvs
Αντικείμενο: [exim-cvs] Include address declared malformed, in error message
Gitweb: https://git.exim.org/exim.git/commitdiff/3b06efc10bd99da03c446e85839c2933b3e309b0
Commit:     3b06efc10bd99da03c446e85839c2933b3e309b0
Parent:     e95b96eb1dc35bae278f237f9d65734305dba6b2
Author:     Jeremy Harris <jgh146exb@???>
AuthorDate: Tue Feb 21 20:58:22 2023 +0000
Committer:  Jeremy Harris <jgh146exb@???>
CommitDate: Tue Feb 21 20:58:22 2023 +0000


    Include address declared malformed, in error message
---
 src/src/verify.c | 2 +-
 test/stderr/0002 | 4 ++--
 test/stderr/0475 | 2 +-
 3 files changed, 4 insertions(+), 4 deletions(-)


diff --git a/src/src/verify.c b/src/src/verify.c
index 125df8d91..5c0a3e408 100644
--- a/src/src/verify.c
+++ b/src/src/verify.c
@@ -2958,7 +2958,7 @@ dots). */
for (t = ss; isdigit(*t) || *t == '.'; ) t++;
if (!*t || (*t == '/' && t != ss))
{
- *error = US"malformed IPv4 address or address mask";
+ *error = string_sprintf("malformed IPv4 address or address mask: %.*s", (int)(t - ss), ss);
return ERROR;
}

diff --git a/test/stderr/0002 b/test/stderr/0002
index 62cc48c9d..c8e10ef9e 100644
--- a/test/stderr/0002
+++ b/test/stderr/0002
@@ -742,9 +742,9 @@ originator: uid=CALLER_UID gid=CALLER_GID login=CALLER name=CALLER_NAME
 sender address = CALLER@???
  1.2.3.4 in "1.2.3"?
   list element: 1.2.3
-  1.2.3.4 in "1.2.3"? no (malformed IPv4 address or address mask)
+  1.2.3.4 in "1.2.3"? no (malformed IPv4 address or address mask: 1.2.3)
   1.2.3.4 in "1.2.3.4/abc"?
    list element: 1.2.3.4/abc
-   1.2.3.4 in "1.2.3.4/abc"? no (malformed IPv4 address or address mask)
+   1.2.3.4 in "1.2.3.4/abc"? no (malformed IPv4 address or address mask: 1.2.3.4)
   search_tidyup called

>>>>>>>>>>>>>>>> Exim pid=p1240 (fresh-exec) terminating with rc=0 >>>>>>>>>>>>>>>>

diff --git a/test/stderr/0475 b/test/stderr/0475
index c3d08c603..4626506f5 100644
--- a/test/stderr/0475
+++ b/test/stderr/0475
@@ -25,7 +25,7 @@ LOG: H=(test) [V4NET.0.0.0] F=<> temporarily rejected RCPT <a1@b>: unknown looku
>>> check hosts = 1.2.3/24
>>> host in "1.2.3/24"?
>>> list element: 1.2.3/24

->>> host in "1.2.3/24"? no (malformed IPv4 address or address mask)
+>>> host in "1.2.3/24"? no (malformed IPv4 address or address mask: 1.2.3)
>>> deny: condition test failed in ACL "a2"
>>> end of ACL "a2": implicit DENY

LOG: H=(test) [V4NET.0.0.0] F=<> rejected RCPT <a2@b>