Mercurial > gnulib
changeset 38211:ed6e125ecb76
md4,md5,sha*: allow _STRING_INLINE_unaligned enable unaligned operation
* lib/md4.c (md4_process_bytes): The existing define is made internal
in recent versions of glibc, so also use this new public define.
* lib/md5.c (md5_process_bytes): Likewise.
* lib/sha1.c (sha1_process_bytes): Likewise.
* lib/sha256.c (sha256_process_bytes): Likewise.
* lib/sha512.c (sha512_process_bytes): Likewise.
author | Pádraig Brady <P@draigBrady.com> |
---|---|
date | Sun, 27 Nov 2016 00:23:14 +0000 |
parents | 91cae3acc973 |
children | 0a8727662e3d |
files | ChangeLog lib/md4.c lib/md5.c lib/sha1.c lib/sha256.c lib/sha512.c |
diffstat | 6 files changed, 15 insertions(+), 5 deletions(-) [+] |
line wrap: on
line diff
--- a/ChangeLog Sat Nov 26 15:39:11 2016 +0000 +++ b/ChangeLog Sun Nov 27 00:23:14 2016 +0000 @@ -1,3 +1,13 @@ +2016-11-27 Pádraig Brady <P@draigBrady.com> + + md4,md5,sha*: allow _STRING_INLINE_unaligned enable unaligned operation + * lib/md4.c (md4_process_bytes): The existing define is made internal + in recent versions of glibc, so also use this new public define. + * lib/md5.c (md5_process_bytes): Likewise. + * lib/sha1.c (sha1_process_bytes): Likewise. + * lib/sha256.c (sha256_process_bytes): Likewise. + * lib/sha512.c (sha512_process_bytes): Likewise. + 2016-11-27 Pádraig Brady <P@draigBrady.com> maint: use a more standard return from mbrtowc test
--- a/lib/md4.c Sat Nov 26 15:39:11 2016 +0000 +++ b/lib/md4.c Sun Nov 27 00:23:14 2016 +0000 @@ -237,7 +237,7 @@ /* Process available complete blocks. */ if (len >= 64) { -#if !_STRING_ARCH_unaligned +#if !(_STRING_ARCH_unaligned || _STRING_INLINE_unaligned) # define UNALIGNED_P(p) ((uintptr_t) (p) % alignof (uint32_t) != 0) if (UNALIGNED_P (buffer)) while (len > 64)
--- a/lib/md5.c Sat Nov 26 15:39:11 2016 +0000 +++ b/lib/md5.c Sun Nov 27 00:23:14 2016 +0000 @@ -259,7 +259,7 @@ /* Process available complete blocks. */ if (len >= 64) { -#if !_STRING_ARCH_unaligned +#if !(_STRING_ARCH_unaligned || _STRING_INLINE_unaligned) # define UNALIGNED_P(p) ((uintptr_t) (p) % alignof (uint32_t) != 0) if (UNALIGNED_P (buffer)) while (len > 64)
--- a/lib/sha1.c Sat Nov 26 15:39:11 2016 +0000 +++ b/lib/sha1.c Sun Nov 27 00:23:14 2016 +0000 @@ -246,7 +246,7 @@ /* Process available complete blocks. */ if (len >= 64) { -#if !_STRING_ARCH_unaligned +#if !(_STRING_ARCH_unaligned || _STRING_INLINE_unaligned) # define UNALIGNED_P(p) ((uintptr_t) (p) % alignof (uint32_t) != 0) if (UNALIGNED_P (buffer)) while (len > 64)
--- a/lib/sha256.c Sat Nov 26 15:39:11 2016 +0000 +++ b/lib/sha256.c Sun Nov 27 00:23:14 2016 +0000 @@ -379,7 +379,7 @@ /* Process available complete blocks. */ if (len >= 64) { -#if !_STRING_ARCH_unaligned +#if !(_STRING_ARCH_unaligned || _STRING_INLINE_unaligned) # define UNALIGNED_P(p) ((uintptr_t) (p) % alignof (uint32_t) != 0) if (UNALIGNED_P (buffer)) while (len > 64)
--- a/lib/sha512.c Sat Nov 26 15:39:11 2016 +0000 +++ b/lib/sha512.c Sun Nov 27 00:23:14 2016 +0000 @@ -387,7 +387,7 @@ /* Process available complete blocks. */ if (len >= 128) { -#if !_STRING_ARCH_unaligned +#if !(_STRING_ARCH_unaligned || _STRING_INLINE_unaligned) # define UNALIGNED_P(p) ((uintptr_t) (p) % alignof (u64) != 0) if (UNALIGNED_P (buffer)) while (len > 128)