-$Cambridge: exim/doc/doc-txt/ChangeLog,v 1.494 2007/03/13 16:37:57 ph10 Exp $
+$Cambridge: exim/doc/doc-txt/ChangeLog,v 1.495 2007/03/14 11:22:23 ph10 Exp $
Change log file for Exim from version 4.21
-------------------------------------------
found. If all hosts are ignored, the behaviour is controlled by the new
host_all_ignored option.
+PH/39 In a list of hosts for manualroute, if one item (either because of multi-
+ homing or because of multiple MX records with /mx) generated more than
+ one IP address, and the following item turned out to be the local host,
+ all the secondary addresses of the first item were incorrectly removed
+ from the list, along with the local host and any following hosts (which
+ is what is supposed to happen).
+
Exim version 4.66
-----------------
-/* $Cambridge: exim/src/src/routers/rf_lookup_hostlist.c,v 1.9 2007/03/13 15:32:48 ph10 Exp $ */
+/* $Cambridge: exim/src/src/routers/rf_lookup_hostlist.c,v 1.10 2007/03/14 11:22:23 ph10 Exp $ */
/*************************************************
* Exim - an Internet mail transport agent *
"self" option in the configuration. */
prev = NULL;
-for (h = addr->host_list; h != NULL; prev = h, h = next_h)
+for (h = addr->host_list; h != NULL; h = next_h)
{
uschar *canonical_name;
int rc, len, port;
next_h = h->next;
- if (h->address != NULL) continue;
+ if (h->address != NULL) { prev = h; continue; }
DEBUG(D_route|D_host_lookup)
debug_printf("finding IP address for %s\n", h->name);
if (hff_code == hff_ignore)
{
if (prev == NULL) addr->host_list = next_h; else prev->next = next_h;
- h = prev; /* Because the loop sets prev to h */
- continue; /* With the next host */
+ continue; /* With the next host, leave prev unchanged */
}
if (hff_code == hff_pass) return PASS;
}
self_send = TRUE;
}
+
+ /* Ensure that prev is the host before next_h; this will not be h if a lookup
+ found multiple addresses or multiple MX records. */
+
+ prev = h;
+ while (prev->next != next_h) prev = prev->next;
}
return OK;
-; $Cambridge: exim/test/dnszones-src/db.test.ex,v 1.5 2006/10/03 15:11:22 ph10 Exp $
+; $Cambridge: exim/test/dnszones-src/db.test.ex,v 1.6 2007/03/14 11:22:23 ph10 Exp $
; This is a testing zone file for use when testing DNS handling in Exim. This
; is a fake zone of no real use - hence no SOA record. The zone name is
MX 5 ten-5.test.ex.
MX 6 ten-6.test.ex.
+; Non-local hosts with different precedence
+
+mxt15 MX 10 ten-1.test.ex.
+ MX 20 ten-2.test.ex.
+
; Large number of IP addresses at one MX value, and then some
; at another, to check that hosts_max_try tries the MX different
; values if it can.
****
exim -DLIST=mxt11a.test.ex/MX:ten-6.test.ex -bt x@random.manual.route
****
+exim -DLIST=mxt15.test.ex/MX:localhost.test.ex -bt x@manual.route
+****
router = r2, transport = t1
host ten-6.test.ex [V4NET.0.0.6]
host ten-1.test.ex [V4NET.0.0.1] MX=6
+x@manual.route
+ router = r1, transport = t1
+ host ten-1.test.ex [V4NET.0.0.1] MX=10
+ host ten-2.test.ex [V4NET.0.0.2] MX=20