Make z_size_t 64 bits when compiling on Windows with Z_SOLO.

Z_SOLO defines z_size_t as an unsigned long. However Windows and
MinGW-w64 are LLP64, where a long is 32 bits, but a size_t is 64
bits. This makes z_size_t, used by adler32_z() and crc32_z(), 64
bits on those systems.
This commit is contained in:
Mark Adler 2023-01-25 21:00:52 -08:00
parent a9b4c1de37
commit fa8cd50ada
3 changed files with 15 additions and 3 deletions

View File

@ -241,7 +241,11 @@
#endif
#ifdef Z_SOLO
typedef unsigned long z_size_t;
# ifdef _WIN64
typedef unsigned long long z_size_t;
# else
typedef unsigned long z_size_t;
# endif
#else
# define z_longlong long long
# if defined(NO_SIZE_T)

View File

@ -243,7 +243,11 @@
#endif
#ifdef Z_SOLO
typedef unsigned long z_size_t;
# ifdef _WIN64
typedef unsigned long long z_size_t;
# else
typedef unsigned long z_size_t;
# endif
#else
# define z_longlong long long
# if defined(NO_SIZE_T)

View File

@ -241,7 +241,11 @@
#endif
#ifdef Z_SOLO
typedef unsigned long z_size_t;
# ifdef _WIN64
typedef unsigned long long z_size_t;
# else
typedef unsigned long z_size_t;
# endif
#else
# define z_longlong long long
# if defined(NO_SIZE_T)