diff options
author | Ulrich Drepper <drepper@gmail.com> | 2011-07-02 13:03:53 -0400 |
---|---|---|
committer | Ulrich Drepper <drepper@gmail.com> | 2011-07-02 13:03:53 -0400 |
commit | feea4948bca7e442edad3f995696f33450549e80 (patch) | |
tree | f0d06f3188f1179aa50dd5281234ed4167422db4 /crypt/sha256.h | |
parent | fcfc776bc6242fdefde0efd7b0c315fbeca08555 (diff) | |
download | glibc-feea4948bca7e442edad3f995696f33450549e80.tar.gz glibc-feea4948bca7e442edad3f995696f33450549e80.tar.xz glibc-feea4948bca7e442edad3f995696f33450549e80.zip |
Fix last patch for big-endian machines
Diffstat (limited to 'crypt/sha256.h')
-rw-r--r-- | crypt/sha256.h | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/crypt/sha256.h b/crypt/sha256.h index fcf61485de..0457bfae40 100644 --- a/crypt/sha256.h +++ b/crypt/sha256.h @@ -24,6 +24,7 @@ #include <limits.h> #include <stdint.h> #include <stdio.h> +#include <endian.h> /* Structure to save state of computation between the single steps. */ @@ -34,6 +35,8 @@ struct sha256_ctx union { uint64_t total64; +#define TOTAL64_low (1 - (BYTE_ORDER == LITTLE_ENDIAN)) +#define TOTAL64_high (BYTE_ORDER == LITTLE_ENDIAN) uint32_t total[2]; }; uint32_t buflen; |