Fix compilation error on mingw.
authorBruno Haible <bruno@clisp.org>
Sun, 2 Aug 2009 18:55:40 +0000 (20:55 +0200)
committerBruno Haible <bruno@clisp.org>
Sun, 2 Aug 2009 18:55:40 +0000 (20:55 +0200)
ChangeLog
lib/gethostname.c

index d0308b9..f3fa7d5 100644 (file)
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,8 @@
+2009-08-02  Bruno Haible  <bruno@clisp.org>
+
+       * lib/gethostname.c: Include limits.h.
+       Reported by Martin Lambers <marlam@marlam.de>.
+
 2009-08-02  Simon Josefsson  <simon@josefsson.org>
             Bruno Haible  <bruno@clisp.org>
 
index ef58a40..6259deb 100644 (file)
@@ -76,6 +76,9 @@ gethostname (char *name, size_t len)
 /* Get winsock2.h. */
 #include <unistd.h>
 
+/* Get INT_MAX.  */
+#include <limits.h>
+
 /* Get set_winsock_errno. */
 #include "w32sock.h"