Fix blake2 final coverity issue

This commit is contained in:
Eric Blankenhorn
2025-07-14 15:04:15 -05:00
parent efdca85aec
commit 9c2ea12563

View File

@@ -358,7 +358,7 @@ int blake2b_final( blake2b_state *S, byte *out, byte outlen )
S->buflen -= BLAKE2B_BLOCKBYTES;
if ( S->buflen > BLAKE2B_BLOCKBYTES )
return BAD_LENGTH_E;
XMEMCPY( S->buf, S->buf + BLAKE2B_BLOCKBYTES, (wolfssl_word)S->buflen );
XMEMMOVE( S->buf, S->buf + BLAKE2B_BLOCKBYTES, (wolfssl_word)S->buflen );
}
blake2b_increment_counter( S, S->buflen );