gethostname: Ensure declaration on NonStop Kernel.
authorBruno Haible <bruno@clisp.org>
Fri, 24 Dec 2010 15:39:10 +0000 (16:39 +0100)
committerBruno Haible <bruno@clisp.org>
Fri, 24 Dec 2010 15:39:10 +0000 (16:39 +0100)
* lib/unistd.in.h: Include <netdb.h> also on NonStop Kernel systems.
Reported by Joachim Schmitz <jojo@schmitz-digital.de>.

ChangeLog
lib/unistd.in.h

index ed375b6..3abaad0 100644 (file)
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,5 +1,11 @@
 2010-12-24  Bruno Haible  <bruno@clisp.org>
 
+       gethostname: Ensure declaration on NonStop Kernel.
+       * lib/unistd.in.h: Include <netdb.h> also on NonStop Kernel systems.
+       Reported by Joachim Schmitz <jojo@schmitz-digital.de>.
+
+2010-12-24  Bruno Haible  <bruno@clisp.org>
+
        sys_select: Ensure all necessary types on NonStop Kernel.
        * lib/sys_select.in.h: If the system does not have <sys/select.h>,
        include <sys/time.h>.
index 1dd06bf..6fe7723 100644 (file)
 # include <io.h>
 #endif
 
-/* AIX and OSF/1 5.1 declare getdomainname in <netdb.h>, not in <unistd.h>.  */
+/* AIX and OSF/1 5.1 declare getdomainname in <netdb.h>, not in <unistd.h>.
+   NonStop Kernel declares gethostname in <netdb.h>, not in <unistd.h>.  */
 /* But avoid namespace pollution on glibc systems.  */
-#if @GNULIB_GETDOMAINNAME@ && (defined _AIX || defined __osf__) \
+#if ((@GNULIB_GETDOMAINNAME@ && (defined _AIX || defined __osf__)) \
+     || (@GNULIB_GETHOSTNAME@ && defined __TANDEM)) \
     && !defined __GLIBC__
 # include <netdb.h>
 #endif