How to get a fqn hostname

Jan H. Schrewe jschrewe at
Mon Oct 8 12:15:20 BST 2001

Werner Modenbach wrote:

> First of all sorry for the OT question.
> In programming a server using Qt classes I need to know the
> fqn hostname of the system.
> The QSocket method address() allways returns "".
> Going to gethostname(...) and getdomainname(...) delivers domainname "".
> uname(...) also returns an empty domainname.
> Any hints? I've no idea where else to look for a solution.
> Thanks.
> - Werner -

try gethostbyname(3) the function is called gethostbyaddress. I don't really 
know if this is the fqdn but it should be a starting point



to unsubscribe from this list send an email to kdevelop-request at with the following body:
unsubscribe »your-email-address«

More information about the KDevelop mailing list