Changeset View
Changeset View
Standalone View
Standalone View
contrib/zlib/gzguts.h
#ifndef GZGUTS_H | |||||
#define GZGUTS_H | |||||
delphij: (similar to crc32.h -- I think we can upstream this but are these changes really needed?) | |||||
/* gzguts.h -- zlib internal header definitions for gz* operations | /* gzguts.h -- zlib internal header definitions for gz* operations | ||||
* Copyright (C) 2004, 2005, 2010, 2011, 2012, 2013, 2016 Mark Adler | * Copyright (C) 2004, 2005, 2010, 2011, 2012, 2013, 2016 Mark Adler | ||||
* For conditions of distribution and use, see copyright notice in zlib.h | * For conditions of distribution and use, see copyright notice in zlib.h | ||||
*/ | */ | ||||
#ifdef _LARGEFILE64_SOURCE | #ifdef _LARGEFILE64_SOURCE | ||||
# ifndef _LARGEFILE_SOURCE | # ifndef _LARGEFILE_SOURCE | ||||
# define _LARGEFILE_SOURCE 1 | # define _LARGEFILE_SOURCE 1 | ||||
▲ Show 20 Lines • Show All 201 Lines • ▼ Show 20 Lines | |||||
/* GT_OFF(x), where x is an unsigned value, is true if x > maximum z_off64_t | /* GT_OFF(x), where x is an unsigned value, is true if x > maximum z_off64_t | ||||
value -- needed when comparing unsigned to z_off64_t, which is signed | value -- needed when comparing unsigned to z_off64_t, which is signed | ||||
(possible z_off64_t types off_t, off64_t, and long are all signed) */ | (possible z_off64_t types off_t, off64_t, and long are all signed) */ | ||||
#ifdef INT_MAX | #ifdef INT_MAX | ||||
# define GT_OFF(x) (sizeof(int) == sizeof(z_off64_t) && (x) > INT_MAX) | # define GT_OFF(x) (sizeof(int) == sizeof(z_off64_t) && (x) > INT_MAX) | ||||
#else | #else | ||||
unsigned ZLIB_INTERNAL gz_intmax OF((void)); | unsigned ZLIB_INTERNAL gz_intmax OF((void)); | ||||
# define GT_OFF(x) (sizeof(int) == sizeof(z_off64_t) && (x) > gz_intmax()) | # define GT_OFF(x) (sizeof(int) == sizeof(z_off64_t) && (x) > gz_intmax()) | ||||
#endif | |||||
#endif | #endif |
(similar to crc32.h -- I think we can upstream this but are these changes really needed?)