aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorMattias Andrée <maandree@kth.se>2019-02-10 18:38:51 +0100
committerMattias Andrée <maandree@kth.se>2019-02-10 18:38:51 +0100
commitf5027cfbf33eaf2c38b563edb2c2beeeea163bce (patch)
treefae73d5cbcbb484e503a5ce4fd6b8060d4ed7c21
parentHMAC: fix support for key lengths that are not multiples of 8 (diff)
downloadlibsha2-f5027cfbf33eaf2c38b563edb2c2beeeea163bce.tar.gz
libsha2-f5027cfbf33eaf2c38b563edb2c2beeeea163bce.tar.bz2
libsha2-f5027cfbf33eaf2c38b563edb2c2beeeea163bce.tar.xz
Fix warnings
Signed-off-by: Mattias Andrée <maandree@kth.se>
-rw-r--r--hmac_unmarshal.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/hmac_unmarshal.c b/hmac_unmarshal.c
index cc62d5c..df32560 100644
--- a/hmac_unmarshal.c
+++ b/hmac_unmarshal.c
@@ -38,10 +38,10 @@ libsha2_hmac_unmarshal(struct libsha2_hmac_state *restrict state, const void *re
return 0;
}
- state->outsize = *(size_t *)&buf[off];
+ state->outsize = *(const size_t *)&buf[off];
off += sizeof(size_t);
- state->inited = *(unsigned char *)&buf[off];
+ state->inited = *(const unsigned char *)&buf[off];
off += sizeof(unsigned char);
memcpy(state->ipad, &buf[off], state->sha2_state.chunk_size);