aboutsummaryrefslogtreecommitdiffstats
path: root/libkeccak_state_copy.c
diff options
context:
space:
mode:
authorMattias Andrée <maandree@kth.se>2024-09-15 00:26:52 +0200
committerMattias Andrée <maandree@kth.se>2024-09-15 00:26:52 +0200
commitb632f93d47c85ea2523fbfbe1b770f7cdfef2a9f (patch)
treefcfb17b708bdd250a9207e45f322891f30a0e016 /libkeccak_state_copy.c
parentUpdate year (diff)
downloadlibkeccak-b632f93d47c85ea2523fbfbe1b770f7cdfef2a9f.tar.gz
libkeccak-b632f93d47c85ea2523fbfbe1b770f7cdfef2a9f.tar.bz2
libkeccak-b632f93d47c85ea2523fbfbe1b770f7cdfef2a9f.tar.xz
m
Signed-off-by: Mattias Andrée <maandree@kth.se>
Diffstat (limited to '')
-rw-r--r--libkeccak_state_copy.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/libkeccak_state_copy.c b/libkeccak_state_copy.c
index bf82fa9..abec573 100644
--- a/libkeccak_state_copy.c
+++ b/libkeccak_state_copy.c
@@ -12,7 +12,7 @@
int
libkeccak_state_copy(struct libkeccak_state *restrict dest, const struct libkeccak_state *restrict src)
{
- memcpy(dest, src, sizeof(struct libkeccak_state));
+ *dest = *src;
if (src->mlen) {
dest->M = malloc(src->mlen * sizeof(char));
if (!dest->M)