[exim] List construction. Whitespace is relevant?

Startseite
Nachricht löschen
Nachricht beantworten
Autor: Andreas Metzler
Datum:  
To: exim-users
Betreff: [exim] List construction. Whitespace is relevant?
Hello,
Lead by
| Leading and trailing white space on each item in a list is ignored.

in spec.txt 6.15 I *stupidly* believed whitespace to be irrelevant in
lists and thought that
hostlist foo = 127.0.0.1 : ::::1
and
hostlist bar = 127.0.0.1:::::1
would be equivalent.[1] However, they are not (Tested in 4.50), while
the former works as expected the latter ("127.0.0.1:::::1") does not.

gethostbyname2(af=inet6) returned 1 (HOST_NOT_FOUND)
gethostbyname2 looked up these IP addresses:
name=1 address=0.0.0.1
host in "127.0.0.1:::::1"? no (end of list)

Thinking about this it s not difficult to come up with an educated
guess: Without the spaces the splitting is obviously not well defined
and exim does something else then what I expected it to do.

Starting with 127.0.0.1:::::1 one has to decide whether to start
grouping from left 127.0.0.1[::][::]:1 or from the right
127.0.0.1:[::][::]1 and ends up with 127.0.0.1 ::1 or
127.0.0.1:: 1.

However I am missing a *big* cluebat about this in spec.txt. (There is
a small one there, when talking about including empty items in lists.)
         thanks, cu andreas
[1]
Yes, I know about
hostlist foo = <; 127.0.0.1 ; ::1
and it is indeed equivalent to
hostlist foo = <;127.0.0.1;::1
-- 
"See, I told you they'd listen to Reason," [SPOILER] Svfurlr fnlf,
fuhggvat qbja gur juveyvat tha.
Neal Stephenson in "Snow Crash"
                                           http://downhill.aus.cc/