diff options
author | Bruce Momjian <bruce@momjian.us> | 2009-01-07 03:39:33 +0000 |
---|---|---|
committer | Bruce Momjian <bruce@momjian.us> | 2009-01-07 03:39:33 +0000 |
commit | d00a3472cfc4f7c429538e2dfdc4656244984f9d (patch) | |
tree | 77294724918876a819a96902daf90ce040d20663 /src/include/port/win32.h | |
parent | 7e518a3d018e4079b69622b538132dade095ec6f (diff) | |
download | postgresql-d00a3472cfc4f7c429538e2dfdc4656244984f9d.tar.gz postgresql-d00a3472cfc4f7c429538e2dfdc4656244984f9d.zip |
Update MinGW so it handles fseeko() similar to Unix.
Diffstat (limited to 'src/include/port/win32.h')
-rw-r--r-- | src/include/port/win32.h | 14 |
1 files changed, 13 insertions, 1 deletions
diff --git a/src/include/port/win32.h b/src/include/port/win32.h index d670576787e..58baa59bffc 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.84 2008/02/17 02:09:31 tgl Exp $ */ +/* $PostgreSQL: pgsql/src/include/port/win32.h,v 1.85 2009/01/07 03:39:33 momjian Exp $ */ #if defined(_MSC_VER) || defined(__BORLANDC__) #define WIN32_ONLY_COMPILER @@ -190,6 +190,18 @@ struct itimerval int setitimer(int which, const struct itimerval * value, struct itimerval * ovalue); +/* + * WIN32 does not provide 64-bit off_t, but does provide the functions operating + * with 64-bit offsets. + */ +#define pgoff_t __int64 +#ifdef WIN32_ONLY_COMPILER +#define fseeko(stream, offset, origin) _fseeki64(stream, offset, origin) +#define ftello(stream) _ftelli64(stream) +#else +#define fseeko(stream, offset, origin) fseeko64(stream, offset, origin) +#define ftello(stream) ftello64(stream) +#endif /* * Supplement to <sys/types.h>. |