aboutsummaryrefslogtreecommitdiff
path: root/crypto/engine
diff options
context:
space:
mode:
authorAndy Polyakov <appro@openssl.org>2005-01-25 22:07:22 +0000
committerAndy Polyakov <appro@openssl.org>2005-01-25 22:07:22 +0000
commite532a6c449049f4cfe611d3b5aa039d47a5d0018 (patch)
tree28c8d6baed30892d9d8f5f47f21ded73b61fa02a /crypto/engine
parent14bcdb087f81e9381cd826d00418f7b956d65741 (diff)
downloadopenssl-e532a6c449049f4cfe611d3b5aa039d47a5d0018.zip
openssl-e532a6c449049f4cfe611d3b5aa039d47a5d0018.tar.gz
openssl-e532a6c449049f4cfe611d3b5aa039d47a5d0018.tar.bz2
FreeBSD 5 refuses to #include <malloc.h>. Fix compiler warning after
http://cvs.openssl.org/chngview?cn=12843.
Diffstat (limited to 'crypto/engine')
-rw-r--r--crypto/engine/eng_padlock.c6
1 files changed, 4 insertions, 2 deletions
diff --git a/crypto/engine/eng_padlock.c b/crypto/engine/eng_padlock.c
index 2d58dcb..4f64a06 100644
--- a/crypto/engine/eng_padlock.c
+++ b/crypto/engine/eng_padlock.c
@@ -118,9 +118,11 @@ void ENGINE_load_padlock (void)
#ifdef COMPILE_HW_PADLOCK
/* We do these includes here to avoid header problems on platforms that
do not have the VIA padlock anyway... */
-#include <malloc.h>
#ifdef _MSC_VER
+# include <malloc.h>
# define alloca _alloca
+#else
+# include <stdlib.h>
#endif
/* Function for ENGINE detection and control */
@@ -357,7 +359,7 @@ static inline void
padlock_bswapl(AES_KEY *ks)
{
size_t i = sizeof(ks->rd_key)/sizeof(ks->rd_key[0]);
- unsigned long *key = ks->rd_key;
+ unsigned int *key = ks->rd_key;
while (i--) {
asm volatile ("bswapl %0" : "+r"(*key));