diff options
Diffstat (limited to 'src/port')
| -rw-r--r-- | src/port/crypt.c | 6 | ||||
| -rw-r--r-- | src/port/getaddrinfo.c | 4 | ||||
| -rw-r--r-- | src/port/inet_aton.c | 4 |
3 files changed, 11 insertions, 3 deletions
diff --git a/src/port/crypt.c b/src/port/crypt.c index dd3e7ecb2a..893e227fcf 100644 --- a/src/port/crypt.c +++ b/src/port/crypt.c @@ -50,8 +50,12 @@ __RCSID("$NetBSD: crypt.c,v 1.18 2001/03/01 14:37:35 wiz Exp $"); #include <sys/types.h> #include <limits.h> #include <stdlib.h> -#include <unistd.h> + +#ifdef WIN32 #include <windows.h> +#else +#include <unistd.h> +#endif static int des_setkey(const char *key); static int des_cipher(const char *in, char *out, long salt, int num_iter); diff --git a/src/port/getaddrinfo.c b/src/port/getaddrinfo.c index 409aef5e9c..3ceaa3e52b 100644 --- a/src/port/getaddrinfo.c +++ b/src/port/getaddrinfo.c @@ -8,7 +8,7 @@ * * * IDENTIFICATION - * $Header: /cvsroot/pgsql/src/port/getaddrinfo.c,v 1.4 2003/06/12 07:36:51 momjian Exp $ + * $Header: /cvsroot/pgsql/src/port/getaddrinfo.c,v 1.5 2003/06/12 08:02:57 momjian Exp $ * *------------------------------------------------------------------------- */ @@ -16,6 +16,7 @@ /* This is intended to be used in both frontend and backend, so use c.h */ #include "c.h" +#if !defined(_MSC_VER) && !defined(__BORLANDC__) #include <sys/types.h> #include <sys/socket.h> #include <netdb.h> @@ -24,6 +25,7 @@ #ifdef HAVE_UNIX_SOCKETS #include <sys/un.h> #endif +#endif #include "getaddrinfo.h" diff --git a/src/port/inet_aton.c b/src/port/inet_aton.c index c55ac4fa51..1f45e92f95 100644 --- a/src/port/inet_aton.c +++ b/src/port/inet_aton.c @@ -1,4 +1,4 @@ -/* $Id: inet_aton.c,v 1.2 2002/09/02 02:47:07 momjian Exp $ +/* $Id: inet_aton.c,v 1.3 2003/06/12 08:02:57 momjian Exp $ * * This inet_aton() function was taken from the GNU C library and * incorporated into Postgres for those systems which do not have this @@ -44,8 +44,10 @@ #include "c.h" +#if !defined(WIN32) || (!defined(_MSC_VER) && !defined(__BORLANDC__)) #include <netinet/in.h> #include <ctype.h> +#endif /* * Check whether "cp" is a valid ascii representation |
