diff options
author | Bruce Momjian <bruce@momjian.us> | 2004-07-23 01:58:36 +0000 |
---|---|---|
committer | Bruce Momjian <bruce@momjian.us> | 2004-07-23 01:58:36 +0000 |
commit | 25c161eba6af6084fe2ea393210c818cdbe211c9 (patch) | |
tree | 99b08f4a021e1761ba0aac8001748467a63baa70 /src | |
parent | acd907bfccafdf4bc1ef9e2beed8d69278de640a (diff) | |
download | postgresql-25c161eba6af6084fe2ea393210c818cdbe211c9.tar.gz postgresql-25c161eba6af6084fe2ea393210c818cdbe211c9.zip |
Move Win32 defines from port.h to win32.h.
Diffstat (limited to 'src')
-rw-r--r-- | src/include/port.h | 12 | ||||
-rw-r--r-- | src/include/port/win32.h | 10 |
2 files changed, 10 insertions, 12 deletions
diff --git a/src/include/port.h b/src/include/port.h index c3e63310a97..9869674a362 100644 --- a/src/include/port.h +++ b/src/include/port.h @@ -6,7 +6,7 @@ * Portions Copyright (c) 1996-2003, PostgreSQL Global Development Group * Portions Copyright (c) 1994, Regents of the University of California * - * $PostgreSQL: pgsql/src/include/port.h,v 1.44 2004/07/21 03:07:40 momjian Exp $ + * $PostgreSQL: pgsql/src/include/port.h,v 1.45 2004/07/23 01:58:36 momjian Exp $ * *------------------------------------------------------------------------- */ @@ -246,13 +246,3 @@ extern int pqGethostbyname(const char *name, struct hostent **result, int *herrno); -/* FIXME: [win32] Placeholder win32 replacements, to allow continued development */ -#ifdef WIN32 -#define fsync(a) _commit(a) -#define sync() _flushall() -#define ftruncate(a,b) chsize(a,b) -#define WEXITSTATUS(w) (((w) >> 8) & 0xff) -#define WIFEXITED(w) (((w) & 0xff) == 0) -#define WIFSIGNALED(w) (((w) & 0x7f) > 0 && (((w) & 0x7f) < 0x7f)) -#define WTERMSIG(w) ((w) & 0x7f) -#endif diff --git a/src/include/port/win32.h b/src/include/port/win32.h index 28a583690d4..6a70bcc095d 100644 --- a/src/include/port/win32.h +++ b/src/include/port/win32.h @@ -1,4 +1,4 @@ -/* $PostgreSQL: pgsql/src/include/port/win32.h,v 1.26 2004/06/24 21:03:33 tgl Exp $ */ +/* $PostgreSQL: pgsql/src/include/port/win32.h,v 1.27 2004/07/23 01:58:36 momjian Exp $ */ /* undefine and redefine after #include */ #undef mkdir @@ -13,6 +13,9 @@ #define mkdir(a,b) mkdir(a) +#define fsync(a) _commit(a) +#define ftruncate(a,b) chsize(a,b) + #define USES_WINSOCK /* defines for dynamic linking on Win32 platform */ @@ -145,6 +148,11 @@ extern int pgwin32_is_service(void); #endif +#define WEXITSTATUS(w) (((w) >> 8) & 0xff) +#define WIFEXITED(w) (((w) & 0xff) == 0) +#define WIFSIGNALED(w) (((w) & 0x7f) > 0 && (((w) & 0x7f) < 0x7f)) +#define WTERMSIG(w) ((w) & 0x7f) + /* Some extra signals */ #define SIGHUP 1 #define SIGQUIT 3 |