Set result to invalid as first step

This commit is contained in:
Andras Fekete
2023-12-19 15:54:25 -05:00
parent f45ffd8802
commit 12192b7683

View File

@@ -265,12 +265,12 @@ int wc_AriaVerify(byte* sig, word32 sigSz, byte* hash, word32 hashSz,
WOLFSSL_ENTER("AriaVerify"); WOLFSSL_ENTER("AriaVerify");
*res = 0; /* Default to invalid signature */
if (sig == NULL || hash == NULL || res == NULL || key == NULL) { if (sig == NULL || hash == NULL || res == NULL || key == NULL) {
return BAD_FUNC_ARG; return BAD_FUNC_ARG;
} }
*res = 0; /* Default to invalid signature */
if (rv == MC_OK) if (rv == MC_OK)
rv = wc_AriaInit(); rv = wc_AriaInit();