Commit b3393401 authored by Richard Levitte's avatar Richard Levitte
Browse files

test/siphash_internal_test.c: ensure the SIPHASH structure is zeroed



Fixes #7641

[extended tests]

Reviewed-by: default avatarMatt Caswell <matt@openssl.org>
(Merged from https://github.com/openssl/openssl/pull/7642)

(cherry picked from commit c7af8b0a267981c25cc42643493289a01ffe1bbd)
parent 42acb69f
Loading
Loading
Loading
Loading
+2 −2
Original line number Original line Diff line number Diff line
@@ -169,7 +169,7 @@ static TESTDATA tests[] = {


static int test_siphash(int idx)
static int test_siphash(int idx)
{
{
    SIPHASH siphash;
    SIPHASH siphash = { 0, };
    TESTDATA test = tests[idx];
    TESTDATA test = tests[idx];
    unsigned char key[SIPHASH_KEY_SIZE];
    unsigned char key[SIPHASH_KEY_SIZE];
    unsigned char in[64];
    unsigned char in[64];
@@ -257,7 +257,7 @@ static int test_siphash(int idx)


static int test_siphash_basic(void)
static int test_siphash_basic(void)
{
{
    SIPHASH siphash;
    SIPHASH siphash = { 0, };
    unsigned char key[SIPHASH_KEY_SIZE];
    unsigned char key[SIPHASH_KEY_SIZE];
    unsigned char output[SIPHASH_MAX_DIGEST_SIZE];
    unsigned char output[SIPHASH_MAX_DIGEST_SIZE];