aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorRob Austein <sra@hactrn.net>2016-06-09 12:54:50 -0400
committerRob Austein <sra@hactrn.net>2016-06-09 12:54:50 -0400
commitc4705484505ed29d17becd57117ea47cb8ab249d (patch)
treef470e5dcc942a43173938cec3931e660029732be
parenta627a489e48cde75f80446e75d057fc1f12a0b98 (diff)
Typo in SHA-224/SHA-256 software core.
-rw-r--r--hash.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/hash.c b/hash.c
index 225a99d..5fface0 100644
--- a/hash.c
+++ b/hash.c
@@ -1031,7 +1031,7 @@ static hal_error_t sw_hash_core_sha256(hal_hash_state_t *state)
uint32_t *H = (uint32_t *) state->core_state, S[8], W[64];
if (state->block_count == 0) {
- switch (state->driver_ctrl_mode & SHA256_MODE_MASK) {
+ switch (state->driver->ctrl_mode & SHA256_MODE_MASK) {
case SHA256_MODE_SHA_224: memcpy(H, sha224_iv, sizeof(sha224_iv)); break;
case SHA256_MODE_SHA_256: memcpy(H, sha256_iv, sizeof(sha256_iv)); break;
default: return HAL_ERROR_IMPOSSIBLE;