Fix invalid assumptions about integer sizes.

This commit is contained in:
Mark de Wever 2010-07-04 04:50:11 +00:00
parent d98f048305
commit 1d1e78b8db

View file

@ -39,6 +39,8 @@ documentation and/or software.
*/
#include <boost/cstdint.hpp>
class MD5 {
public:
@ -54,9 +56,9 @@ public:
private:
// first, some types:
typedef unsigned int uint4; // assumes integer is 4 words long
typedef unsigned short int uint2; // assumes short integer is 2 words long
typedef unsigned char uint1; // assumes char is 1 word long
typedef boost::uint32_t uint4;
typedef boost::uint16_t uint2;
typedef boost::uint8_t uint1;
// next, the private data:
uint4 state[4];