mirror of
https://github.com/wolfSSL/wolfssl.git
synced 2026-01-27 07:52:23 +01:00
Improve wc_HmacUpdate to return early if input length == 0. Fixes QAT issue with HKDF test.
This commit is contained in:
@@ -814,6 +814,9 @@ int wc_HmacUpdate(Hmac* hmac, const byte* msg, word32 length)
|
||||
if (hmac == NULL || (msg == NULL && length > 0)) {
|
||||
return BAD_FUNC_ARG;
|
||||
}
|
||||
if (length == 0) {
|
||||
return 0; /* nothing to do, return success */
|
||||
}
|
||||
|
||||
#ifdef WOLF_CRYPTO_CB
|
||||
if (hmac->devId != INVALID_DEVID) {
|
||||
|
||||
Reference in New Issue
Block a user