From 90cfcabe9570779a66bd5c3d954eea6081f7e2b1 Mon Sep 17 00:00:00 2001 From: Paul Eggert Date: Mon, 2 Aug 2004 05:20:05 +0000 Subject: Don't include . Include if available, as it defines symbols like UINT32_MAX on Solaris 8. (md5_uint32): Assume uint32_t exists; Autoconf will define it otherwise (if the host has a 32-bit unsigned type, anyway). --- lib/md5.h | 22 +++------------------- 1 file changed, 3 insertions(+), 19 deletions(-) diff --git a/lib/md5.h b/lib/md5.h index 7cc0c6fd5..661de4bba 100644 --- a/lib/md5.h +++ b/lib/md5.h @@ -25,31 +25,15 @@ #define _MD5_H 1 #include -#include - -/* The following contortions are an attempt to use the C preprocessor - to determine an unsigned integral type that is exactly 32 bits wide. */ +#if HAVE_INTTYPES_H +# include +#endif #if HAVE_STDINT_H || _LIBC # include #endif -#ifdef UINT32_MAX typedef uint32_t md5_uint32; -#else -# define UINT_MAX_32_BITS 4294967295U -# if UINT_MAX == UINT_MAX_32_BITS - typedef unsigned int md5_uint32; -# elif USHRT_MAX == UINT_MAX_32_BITS - typedef unsigned short int md5_uint32; -# elif ULONG_MAX == UINT_MAX_32_BITS - typedef unsigned long md5_uint32; -# else - /* The following line is intended to evoke an error. - Using #error is not portable enough. */ - "Cannot determine unsigned 32-bit data type." -# endif -#endif /* Structure to save state of computation between the single steps. */ struct md5_ctx -- cgit v1.2.3-54-g00ecf