Fix fopen64, ftello64, fseeko64 declarations on all platforms

pull/3556/head
Jean-Louis 2020-12-24 03:18:09 +01:00
parent 54be7ac582
commit c464d01778
1 changed files with 17 additions and 18 deletions

View File

@ -21,25 +21,24 @@
#include "zlib.h" #include "zlib.h"
#if defined(USE_FILE32API) #if defined(USE_FILE32API)
# define fopen64 fopen # define fopen64 fopen
# define ftello64 ftell # define ftello64 ftell
# define fseeko64 fseek # define fseeko64 fseek
#else #else
# if defined(__FreeBSD__) || defined(__NetBSD__) || defined(__DragonFly__) || defined(__OpenBSD__) || defined(__APPLE__) || defined(__ANDROID__) #if defined(_MSC_VER)
# define fopen64 fopen # define fopen64 fopen
# define ftello64 ftello # if (_MSC_VER >= 1400) && (!(defined(NO_MSCVER_FILE64_FUNC)))
# define fseeko64 fseeko # define ftello64 _ftelli64
# endif # define fseeko64 _fseeki64
# ifdef _MSC_VER # else /* old MSC */
# define fopen64 fopen # define ftello64 ftell
# if (_MSC_VER >= 1400) && (!(defined(NO_MSCVER_FILE64_FUNC))) # define fseeko64 fseek
# define ftello64 _ftelli64 # endif
# define fseeko64 _fseeki64 #else
# else /* old MSC */ # define fopen64 fopen
# define ftello64 ftell # define ftello64 ftello
# define fseeko64 fseek # define fseeko64 fseeko
# endif #endif
# endif
#endif #endif
#ifdef __cplusplus #ifdef __cplusplus