Gethostname and IPv6

Posted by Indhu Bharathi on Stack Overflow See other posts from Stack Overflow or by Indhu Bharathi
Published on 2010-05-11T14:30:10Z Indexed on 2010/05/11 14:34 UTC
Read the original article Hit count: 454

Filed under:
|
|
|

Microsoft recommends not to use 'gethostname' on IPv6 and instead use 'getaddrinfo' or 'getnameinfo'.

http://msdn.microsoft.com/en-us/library/ms899604.aspx

But 'gethostname' doesn't seem to have any problem working on IPv6. Does anyone know any reason why 'gethostname' is not recommended on IPv6?

© Stack Overflow or respective owner

Related posts about c++

Related posts about Windows