Added consistent include file handling for MAXHOSTNAMELEN.
authorBruce Momjian
Sun, 13 Oct 1996 04:50:27 +0000 (04:50 +0000)
committerBruce Momjian
Sun, 13 Oct 1996 04:50:27 +0000 (04:50 +0000)
If I have introduced any syntax errors with this, I will patch them in
the morning, and Marc will have a good laugh.

src/backend/libpq/auth.c
src/backend/postmaster/postmaster.c
src/backend/tcop/postgres.c
src/bin/pg4_dump/pg4_dump.c
src/interfaces/libpq/fe-auth.c

index 8c253f5c39fbb84371913e92f0d5cd18cb4256f7..3a42c236e03b1a3bb378ef067359a864dd1fdb8f 100644 (file)
@@ -7,7 +7,7 @@
  *
  *
  * IDENTIFICATION
- *    $Header: /cvsroot/pgsql/src/backend/libpq/auth.c,v 1.3 1996/10/12 07:47:08 bryanh Exp $
+ *    $Header: /cvsroot/pgsql/src/backend/libpq/auth.c,v 1.4 1996/10/13 04:49:32 momjian Exp $
  *
  *-------------------------------------------------------------------------
  */
  */
 #include 
 #include 
-#include  /* for MAX{HOSTNAME,PATH}LEN, NOFILE */
+#include  /* for MAXHOSTNAMELEN on most */
+#ifndef  MAXHOSTNAMELEN
+#include  /* for MAXHOSTNAMELEN on some */
+#endif
 #include 
 #include              /* isspace() declaration */
 
index 3a2e103c34f0bfb0b345e549b20121875210ed5c..15b0e10b2040308a5ec391978f4baeeb5e38274c 100644 (file)
@@ -10,7 +10,7 @@
  *
  *
  * IDENTIFICATION
- *    $Header: /cvsroot/pgsql/src/backend/postmaster/postmaster.c,v 1.13 1996/10/13 04:01:05 bryanh Exp $
+ *    $Header: /cvsroot/pgsql/src/backend/postmaster/postmaster.c,v 1.14 1996/10/13 04:49:48 momjian Exp $
  *
  * NOTES
  *
 #include       /* for umask */
 #include 
 #include      /* for MAXHOSTNAMELEN on most */
-
-#if defined(USES_WINSOCK)
-# include 
-# include 
-# define MAXINT        INT_MAX
+#ifndef MAXHOSTNAMELEN
+#include      /* for MAXHOSTNAMELEN on some */
+#endif
+#if defined(USE_LIMITS_H)
+# include 
+# define MAXINT        INT_MAX
 #else
-# include         /* for MAXHOSTNAMELEN on some */
-# ifndef MAXHOSTNAMELEN        /* for MAXHOSTNAMELEN everywhere else */
-#  include 
-#  define MAXHOSTNAMELEN       MAXDNAME
-# endif
-# if defined(USE_LIMITS_H)
-#  include 
-#  define MAXINT       INT_MAX
-# else
-#  include 
-# endif /* !USE_LIMITS_H */
-# include 
-#endif /* USES_WINSOCK */
+# include 
+#endif /* !USE_LIMITS_H */
+#include 
 
 #include 
 #include 
index dd638c03c7267b0986964cccd9880ea35dc1d6b9..7ac58d8253a361dc45c1bc30610a34955f968563 100644 (file)
@@ -7,7 +7,7 @@
  *
  *
  * IDENTIFICATION
- *    $Header: /cvsroot/pgsql/src/backend/tcop/postgres.c,v 1.9 1996/10/04 20:16:32 scrappy Exp $
+ *    $Header: /cvsroot/pgsql/src/backend/tcop/postgres.c,v 1.10 1996/10/13 04:49:57 momjian Exp $
  *
  * NOTES
  *    this is the "main" module of the postgres backend and
 #include 
 #include 
 #include      /* for MAXHOSTNAMELEN on most */
-#ifndef WIN32
+#ifndef MAXHOSTNAMELEN
 #include      /* for MAXHOSTNAMELEN on some */
-#ifndef MAXHOSTNAMELEN     /* for MAXHOSTNAMELEN everywhere else */
-#include 
-#define MAXHOSTNAMELEN     MAXDNAME
 #endif
-#endif /* WIN32 */
 #include 
 #ifdef PORTNAME_aix
 #include 
@@ -1269,7 +1265,7 @@ PostgresMain(int argc, char *argv[])
      */
     if (IsUnderPostmaster == false) {
    puts("\nPOSTGRES backend interactive interface");
-   puts("$Revision: 1.9 $ $Date: 1996/10/04 20:16:32 $");
+   puts("$Revision: 1.10 $ $Date: 1996/10/13 04:49:57 $");
     }
     
     /* ----------------
index 9944ca1190ebb88b47138642009b1cf520b11f63..6f484d48c64eb83d048b3e0dea9511d25a7a0efa 100644 (file)
 #include 
 #include 
 #include  /* for MAXHOSTNAMELEN on most */
-#if defined(PORTNAME_sparc_solaris) || defined(PORTNAME_i386_solaris)
+#ifndef  MAXHOSTNAMELEN
 #include  /* for MAXHOSTNAMELEN on some */
 #endif
+#endif
 
 #include "tmp/postgres.h"
 #include "tmp/libpq-fe.h"
index 88350b84b48f28a98e4888d7f22de1024ecc3686..18a5a6f08fe211b7eedef4890f81902ffd0aa3da 100644 (file)
@@ -7,7 +7,7 @@
  *
  *
  * IDENTIFICATION
- *    $Header: /cvsroot/pgsql/src/interfaces/libpq/fe-auth.c,v 1.4 1996/08/06 16:16:42 scrappy Exp $
+ *    $Header: /cvsroot/pgsql/src/interfaces/libpq/fe-auth.c,v 1.5 1996/10/13 04:50:27 momjian Exp $
  *
  *-------------------------------------------------------------------------
  */
  */
 #include 
 #include 
-#include  /* for MAX{HOSTNAME,PATH}LEN, NOFILE */
+#include  /* for MAXHOSTNAMELEN on most */
+#ifndef  MAXHOSTNAMELEN
+#include  /* for MAXHOSTNAMELEN on some */
+#endif
 #include 
 #include 
 #include