Browse Source

sha256: Make our u32 and u8 fields the same size

These are just aliases to a buffer: its customary for these to
have the same size, and makes sizeof() consistent in case anyone
decides to use the members instead of the containing union.

Signed-off-by: Jon Griffiths <jon_p_griffiths@yahoo.com>
Jon Griffiths 10 years ago
parent
commit
60b3090a54
1 changed files with 1 additions and 1 deletions
  1. 1 1
      ccan/crypto/sha256/sha256.h

+ 1 - 1
ccan/crypto/sha256/sha256.h

@@ -49,7 +49,7 @@ struct sha256_ctx {
 	uint32_t s[8];
 	uint64_t bytes;
 	union {
-		uint32_t u32[8];
+		uint32_t u32[16];
 		unsigned char u8[64];
 	} buf;
 #endif