diff options
| author | jsing <> | 2023-08-15 08:30:49 +0000 |
|---|---|---|
| committer | jsing <> | 2023-08-15 08:30:49 +0000 |
| commit | 5f786fd616680aca71e0c9311098ceabd1bab4e5 (patch) | |
| tree | e9c9ae9ee4d25854998a82ce70f3b7e91aa7d328 /src | |
| parent | 8660820bb1807d3aedbb78b859c4fefc106d4b85 (diff) | |
| download | openbsd-5f786fd616680aca71e0c9311098ceabd1bab4e5.tar.gz openbsd-5f786fd616680aca71e0c9311098ceabd1bab4e5.tar.bz2 openbsd-5f786fd616680aca71e0c9311098ceabd1bab4e5.zip | |
Condition only on #ifdef MD5_ASM.
There are a bunch of unnecessary preprocessor directives - just condition
on MD5_ASM, the same as we do elsewhere.
ok tb@
Diffstat (limited to 'src')
| -rw-r--r-- | src/lib/libcrypto/md5/md5.c | 20 |
1 files changed, 5 insertions, 15 deletions
diff --git a/src/lib/libcrypto/md5/md5.c b/src/lib/libcrypto/md5/md5.c index be954d277e..fcec022724 100644 --- a/src/lib/libcrypto/md5/md5.c +++ b/src/lib/libcrypto/md5/md5.c | |||
| @@ -1,4 +1,4 @@ | |||
| 1 | /* $OpenBSD: md5.c,v 1.15 2023/08/14 15:48:16 jsing Exp $ */ | 1 | /* $OpenBSD: md5.c,v 1.16 2023/08/15 08:30:49 jsing Exp $ */ |
| 2 | /* Copyright (C) 1995-1998 Eric Young (eay@cryptsoft.com) | 2 | /* Copyright (C) 1995-1998 Eric Young (eay@cryptsoft.com) |
| 3 | * All rights reserved. | 3 | * All rights reserved. |
| 4 | * | 4 | * |
| @@ -65,20 +65,10 @@ | |||
| 65 | #include <openssl/md5.h> | 65 | #include <openssl/md5.h> |
| 66 | 66 | ||
| 67 | #ifdef MD5_ASM | 67 | #ifdef MD5_ASM |
| 68 | # if defined(__i386) || defined(__i386__) || defined(_M_IX86) || defined(__INTEL__) || \ | 68 | void md5_block_asm_data_order(MD5_CTX *c, const void *p, size_t num); |
| 69 | defined(__x86_64) || defined(__x86_64__) || defined(_M_AMD64) || defined(_M_X64) | 69 | #define md5_block_data_order md5_block_asm_data_order |
| 70 | # define md5_block_data_order md5_block_asm_data_order | ||
| 71 | # elif defined(__ia64) || defined(__ia64__) || defined(_M_IA64) | ||
| 72 | # define md5_block_data_order md5_block_asm_data_order | ||
| 73 | # endif | ||
| 74 | #endif | 70 | #endif |
| 75 | 71 | ||
| 76 | __BEGIN_HIDDEN_DECLS | ||
| 77 | |||
| 78 | void md5_block_data_order(MD5_CTX *c, const void *p, size_t num); | ||
| 79 | |||
| 80 | __END_HIDDEN_DECLS | ||
| 81 | |||
| 82 | #define DATA_ORDER_IS_LITTLE_ENDIAN | 72 | #define DATA_ORDER_IS_LITTLE_ENDIAN |
| 83 | 73 | ||
| 84 | #define HASH_LONG MD5_LONG | 74 | #define HASH_LONG MD5_LONG |
| @@ -132,8 +122,8 @@ __END_HIDDEN_DECLS | |||
| 132 | /* Implemented from RFC1321 The MD5 Message-Digest Algorithm | 122 | /* Implemented from RFC1321 The MD5 Message-Digest Algorithm |
| 133 | */ | 123 | */ |
| 134 | 124 | ||
| 135 | #ifndef md5_block_data_order | 125 | #ifndef MD5_ASM |
| 136 | void | 126 | static void |
| 137 | md5_block_data_order(MD5_CTX *c, const void *data_, size_t num) | 127 | md5_block_data_order(MD5_CTX *c, const void *data_, size_t num) |
| 138 | { | 128 | { |
| 139 | const unsigned char *data = data_; | 129 | const unsigned char *data = data_; |
