From 2916d56c9d8a14df739e997d1ac2acb0d447e4de Mon Sep 17 00:00:00 2001 From: phk Date: Tue, 22 Oct 1996 16:27:47 +0000 Subject: close bin/1648 libmd not 64bit safe. if something fails to compile now, you need to add #include Partially Submitted by: Jason Thorpe --- lib/libmd/md2c.c | 5 +++-- lib/libmd/md4.h | 4 ++-- lib/libmd/md4c.c | 7 ++++--- lib/libmd/md5.h | 4 ++-- lib/libmd/md5c.c | 7 ++++--- 5 files changed, 15 insertions(+), 12 deletions(-) (limited to 'lib/libmd') diff --git a/lib/libmd/md2c.c b/lib/libmd/md2c.c index d311758..6659f1b 100644 --- a/lib/libmd/md2c.c +++ b/lib/libmd/md2c.c @@ -22,11 +22,12 @@ #include "md2.h" #include +#include typedef unsigned char *POINTER; -typedef unsigned short int UINT2; -typedef unsigned long int UINT4; +typedef u_int16_t UINT2; +typedef u_int32_t UINT4; #define PROTO_LIST(list) list diff --git a/lib/libmd/md4.h b/lib/libmd/md4.h index ea4ec8a..237ecc8 100644 --- a/lib/libmd/md4.h +++ b/lib/libmd/md4.h @@ -27,8 +27,8 @@ #define _MD4_H_ /* MD4 context. */ typedef struct MD4Context { - unsigned long state[4]; /* state (ABCD) */ - unsigned long count[2]; /* number of bits, modulo 2^64 (lsb first) */ + u_int32_t state[4]; /* state (ABCD) */ + u_int32_t count[2]; /* number of bits, modulo 2^64 (lsb first) */ unsigned char buffer[64]; /* input buffer */ } MD4_CTX; diff --git a/lib/libmd/md4c.c b/lib/libmd/md4c.c index 7e90ec3..c13d073 100644 --- a/lib/libmd/md4c.c +++ b/lib/libmd/md4c.c @@ -23,12 +23,13 @@ documentation and/or software. */ -#include "md4.h" +#include #include +#include "md4.h" typedef unsigned char *POINTER; -typedef unsigned short int UINT2; -typedef unsigned long int UINT4; +typedef u_int16_t UINT2; +typedef u_int32_t UINT4; #define PROTO_LIST(list) list diff --git a/lib/libmd/md5.h b/lib/libmd/md5.h index da0c116..422cd7b 100644 --- a/lib/libmd/md5.h +++ b/lib/libmd/md5.h @@ -28,8 +28,8 @@ documentation and/or software. #define _MD5_H_ /* MD5 context. */ typedef struct MD5Context { - unsigned long state[4]; /* state (ABCD) */ - unsigned long count[2]; /* number of bits, modulo 2^64 (lsb first) */ + u_int32_t state[4]; /* state (ABCD) */ + u_int32_t count[2]; /* number of bits, modulo 2^64 (lsb first) */ unsigned char buffer[64]; /* input buffer */ } MD5_CTX; diff --git a/lib/libmd/md5c.c b/lib/libmd/md5c.c index 5c35b5b..ed4a7b6 100644 --- a/lib/libmd/md5c.c +++ b/lib/libmd/md5c.c @@ -24,12 +24,13 @@ These notices must be retained in any copies of any part of this documentation and/or software. */ -#include "md5.h" +#include #include +#include "md5.h" typedef unsigned char *POINTER; -typedef unsigned short int UINT2; -typedef unsigned long int UINT4; +typedef u_int16_t UINT2; +typedef u_int32_t UINT4; #define PROTO_LIST(list) list -- cgit v1.1