Really enable big endian support in md5.c

This commit is contained in:
Con Kolivas 2011-03-23 00:56:35 +11:00
parent 74f7b3deb6
commit 64bba65c11

10
md5.c
View file

@ -36,11 +36,17 @@
# include "unlocked-io.h" # include "unlocked-io.h"
#endif #endif
#ifdef _LIBC #ifdef HAVE_ENDIAN_H
# include <endian.h> # include <endian.h>
#elif HAVE_SYS_ENDIAN_H
# include <sys/endian.h>
#endif
#ifdef HAVE_ARPA_INET_H
# include <arpa/inet.h>
#endif
# if __BYTE_ORDER == __BIG_ENDIAN # if __BYTE_ORDER == __BIG_ENDIAN
# define WORDS_BIGENDIAN 1 # define WORDS_BIGENDIAN 1
# endif
/* We need to keep the namespace clean so define the MD5 function /* We need to keep the namespace clean so define the MD5 function
protected using leading __ . */ protected using leading __ . */
# define md5_init_ctx __md5_init_ctx # define md5_init_ctx __md5_init_ctx