Fix the calculation of the most negative int64_t value, which

is used on systems that lack C99 headers (such as FreeBSD 4).
This commit is contained in:
kientzle 2004-08-07 06:38:40 +00:00
parent 91c781f0d7
commit 77fb4fcf22
2 changed files with 3 additions and 3 deletions

View File

@ -8,7 +8,7 @@
LIB= archive
SHLIB_MAJOR= 1
VERSION= 1.00.007
VERSION= 1.00.009
ARCHIVE_API_FEATURE= 1
CFLAGS+= -DPACKAGE_NAME=\"lib${LIB}\"
CFLAGS+= -DPACKAGE_VERSION=\"${VERSION}\"
@ -180,7 +180,7 @@ ${SRCS:S/.c$/.o/}: archive.h
CLEANFILES+= archive.h
# Build archive.h from archive.h.in
archive.h: archive.h.in
archive.h: archive.h.in Makefile
cat ${.CURDIR}/archive.h.in | \
sed 's/@ARCHIVE_API_VERSION@/${SHLIB_MAJOR}/' | \
sed 's/@ARCHIVE_API_FEATURE@/${ARCHIVE_API_FEATURE}/' | \

View File

@ -192,7 +192,7 @@ static const int64_t max_int64 = (int64_t)((~(uint64_t)0) >> 1);
#ifdef INT64_MIN
static const int64_t min_int64 = INT64_MIN;
#else
static const int64_t min_int64 = (int64_t)(~max_int64);
static const int64_t min_int64 = (int64_t)(~((~(uint64_t)0) >> 1));
#endif
int