summaryrefslogtreecommitdiff
path: root/crypto/md32_common.h
diff options
context:
space:
mode:
authorAndy Polyakov <appro@openssl.org>1999-08-28 12:41:03 +0000
committerAndy Polyakov <appro@openssl.org>1999-08-28 12:41:03 +0000
commit1cbde6e4fa6a5bde5a62109acb58e02f1990608f (patch)
tree30f9318851bfee6f454850abcb73e46af77d5073 /crypto/md32_common.h
parent87a25f90324aa6f48d903a22852ff2ce1aa9dde0 (diff)
downloadopenssl-new-1cbde6e4fa6a5bde5a62109acb58e02f1990608f.tar.gz
md32_common.h update and accompanying MD5 update.
Diffstat (limited to 'crypto/md32_common.h')
-rw-r--r--crypto/md32_common.h15
1 files changed, 10 insertions, 5 deletions
diff --git a/crypto/md32_common.h b/crypto/md32_common.h
index 2b91f9eef2..5e62d40523 100644
--- a/crypto/md32_common.h
+++ b/crypto/md32_common.h
@@ -94,6 +94,8 @@
* in original (data) byte order, implemented externally (it
* actually is optional if data and host are of the same
* "endianess").
+ * HASH_MAKE_STRING
+ * macro convering context variables to an ASCII hash string.
*
* Optional macros:
*
@@ -178,7 +180,9 @@
#undef ROTATE
#ifndef PEDANTIC
# if defined(_MSC_VER)
-# define ROTATE(a,n) _lrotl(a,n)
+# define ROTATE(a,n) _lrotl(a,n)
+# elif defined(__MWERKS__)
+# define ROTATE(a,n) __rol(a,n)
# elif defined(__GNUC__) && __GNUC__>=2 && !defined(NO_ASM)
/*
* Some GNU C inline assembler templates. Note that these are
@@ -581,10 +585,11 @@ void HASH_FINAL (unsigned char *md, HASH_CTX *c)
#endif
HASH_BLOCK_HOST_ORDER (c,p,1);
- l=c->A; HOST_l2c(l,md);
- l=c->B; HOST_l2c(l,md);
- l=c->C; HOST_l2c(l,md);
- l=c->D; HOST_l2c(l,md);
+#ifndef HASH_MAKE_STRING
+#error "HASH_MAKE_STRING must be defined!"
+#else
+ HASH_MAKE_STRING(c,md);
+#endif
c->num=0;
/* clear stuff, HASH_BLOCK may be leaving some stuff on the stack