aboutsummaryrefslogtreecommitdiff
path: root/rpc_hash.c
diff options
context:
space:
mode:
Diffstat (limited to 'rpc_hash.c')
-rw-r--r--rpc_hash.c24
1 files changed, 12 insertions, 12 deletions
diff --git a/rpc_hash.c b/rpc_hash.c
index 7cae484..0811e81 100644
--- a/rpc_hash.c
+++ b/rpc_hash.c
@@ -157,12 +157,12 @@ static inline void free_handle(handle_slot_t *slot)
static inline const hal_hash_descriptor_t *alg_to_descriptor(const hal_digest_algorithm_t alg)
{
switch (alg) {
- case hal_digest_algorithm_sha1: return hal_hash_sha1;
- case hal_digest_algorithm_sha256: return hal_hash_sha256;
- case hal_digest_algorithm_sha512_224: return hal_hash_sha512_224;
- case hal_digest_algorithm_sha512_256: return hal_hash_sha512_256;
- case hal_digest_algorithm_sha384: return hal_hash_sha384;
- case hal_digest_algorithm_sha512: return hal_hash_sha512;
+ case HAL_DIGEST_ALGORITHM_SHA1: return hal_hash_sha1;
+ case HAL_DIGEST_ALGORITHM_SHA256: return hal_hash_sha256;
+ case HAL_DIGEST_ALGORITHM_SHA512_224: return hal_hash_sha512_224;
+ case HAL_DIGEST_ALGORITHM_SHA512_256: return hal_hash_sha512_256;
+ case HAL_DIGEST_ALGORITHM_SHA384: return hal_hash_sha384;
+ case HAL_DIGEST_ALGORITHM_SHA512: return hal_hash_sha512;
default: return NULL;
}
}
@@ -303,12 +303,12 @@ static hal_error_t finalize(const hal_hash_handle_t handle,
}
const hal_rpc_hash_dispatch_t hal_rpc_local_hash_dispatch = {
- get_digest_length,
- get_digest_algorithm_id,
- get_algorithm,
- initialize,
- update,
- finalize
+ .get_digest_length = get_digest_length,
+ .get_digest_algorithm_id = get_digest_algorithm_id,
+ .get_algorithm = get_algorithm,
+ .initialize = initialize,
+ .update = update,
+ .finalize = finalize
};
/*