[ something ate my message, second try ]
there's a longstanding issue in ngircd, at least on (Debian) Linux
using glibc: Some tests in src/festsuite rely on a certain order of
the entries in /etc/hosts.
Appearently the first entry that points to 127.0.0.1 is returned
when getnameinfo, same for gethostbyaddr, is called for that IP
address. Up to three tests (misc, who, whois) assume the result is
or begins with "localhost", and will fail otherwise.
This usually happens if the administrator of the site where ngircd is
built has decided to have an entry about the host name at the first
place in /etc/hosts. Now I'm not aware whether there's a rule about
this at all. And even if, it is violated that often I'd call it a bad
idea to try educating users. Instead, ngircd should work around it.
Two ways I can think of:
Before running the tests, call getnameinfo on 127.0.0.1 and patch
any non-"localhost*" result into the expect files. This looks
kludgy, especially since some tests use pattern matching like in
'send "who ??cal*ho*\r"'. So after a few hours of trying, a second
Enhance ngircd's resolver to resolve 127.0.0.1 into "localhost" no
matter what. To avoid surprises, this should be controllable by
another command line option. Using LD_PRELOAD during the tests was a