bug-inetutils
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [bug-inetutils] dnsdomainname, domainname, nisdomainname, ypdomainna


From: Simon Josefsson
Subject: Re: [bug-inetutils] dnsdomainname, domainname, nisdomainname, ypdomainname
Date: Thu, 15 Mar 2012 10:19:01 +0100
User-agent: Gnus/5.130003 (Ma Gnus v0.3) Emacs/24.0.94 (gnu/linux)

Simon Josefsson <address@hidden> writes:

> Mats Erik Andersson <address@hidden> writes:
>
>> onsdag den 14 mars 2012 klockan 08:43 skrev Simon Josefsson detta:
>>> Mats Erik Andersson <address@hidden> writes:
>>> 
>>> > The test script is problematic:
>>> >
>>> >   b) A particular system may be legally set up in a manner that
>>> >      a non-fully qualified host name is returned by xgethostname()
>>> >      and ensuing resolution. This can be accomplished by
>>> >
>>> >         # /etc/hosts
>>> >         10.0.1.1    dag  dag.utan.ljus
>>> >
>>> >         # /etc/nsswitch.conf
>>> >         hosts   files dns
>>> >
>>> >         $ hostname
>>> >         dag
>>> >
>>> >      Thus "dnsdomainname" fails with "cannot qualify host name: dag",
>>> >      again producing a false negative in the test script. This happened
>>> >      to be the case on my OpenSolaris/OpenIndiana systems!
>>> >
>>> > The test script should report "skipping" in either of the above cases.
>>> 
>>> You are right.  I pushed a patch that should make the self-test pass,
>>> however it would nice to improve it eventually to other error situations
>>> (I've added a FIXME discussing this).  I can't think of any easy way to
>>> do that in a portable way though.
>>
>> I think we can defend code in "src/dnsdomainname.c" which returns
>> the empty string in the second of my cases, and doing so with exit
>> status naught, thus claiming normal condition.
>
> I agree, Debian's dnsdomainname appears to behave that way already.

I have fixed this now.

Thanks,
/Simon



reply via email to

[Prev in Thread] Current Thread [Next in Thread]