diff options
Diffstat (limited to 'libraries/base/include/HsBase.h')
-rw-r--r-- | libraries/base/include/HsBase.h | 11 |
1 files changed, 4 insertions, 7 deletions
diff --git a/libraries/base/include/HsBase.h b/libraries/base/include/HsBase.h index 12edce964d..d841141be2 100644 --- a/libraries/base/include/HsBase.h +++ b/libraries/base/include/HsBase.h @@ -280,15 +280,12 @@ __hscore_o_nonblock( void ) INLINE int __hscore_ftruncate( int fd, off_t where ) { -#if defined(HAVE_FTRUNCATE) +#if defined(HAVE__CHSIZE_S) + return _chsize_s(fd,where); +#elif defined(HAVE_FTRUNCATE) return ftruncate(fd,where); -#elif defined(HAVE__CHSIZE) - return _chsize(fd,where); #else -// ToDo: we should use _chsize_s() on Windows which allows a 64-bit -// offset, but it doesn't seem to be available from mingw at this time -// --SDM (01/2008) -#error at least ftruncate or _chsize functions are required to build +#error at least _chsize_s or ftruncate functions are required to build #endif } |