From b7d82a478eafbde7dbe7b6bfb1630becfed49f39 Mon Sep 17 00:00:00 2001 From: Magnus Lundborg Date: Thu, 16 May 2013 09:21:45 +0200 Subject: Attempt to fix compilations in MSVS. Check if compiling on Windows. Use __inline instead of inline. diff --git a/include/md5.h b/include/md5.h index 15719fd..3652594 100644 --- a/include/md5.h +++ b/include/md5.h @@ -49,6 +49,12 @@ #ifndef md5_INCLUDED # define md5_INCLUDED +#ifndef USE_WINDOWS +#if defined(WIN32) || defined(_WIN32) || defined(WIN64) || defined(_WIN64) +#define USE_WINDOWS +#endif /* win32... */ +#endif /* not defined USE_WINDOWS */ + /* * This package supports both compile-time and run-time determination of CPU * byte order. If ARCH_IS_BIG_ENDIAN is defined as 0, the code will be diff --git a/src/lib/md5.c b/src/lib/md5.c index 8bbde52..57c2138 100644 --- a/src/lib/md5.c +++ b/src/lib/md5.c @@ -169,8 +169,11 @@ #define T63 0x2ad7d2bb #define T64 /* 0xeb86d391 */ (T_MASK ^ 0x14792c6e) - +#ifdef USE_WINDOWS static inline void +#else +static __inline void +#endif md5_process(md5_state_t *pms, const md5_byte_t *data /*[64]*/) { md5_word_t -- cgit v0.10.1