ghmac: Use new g_alloca0() function

Replace `g_alloca()` and `memset()` with `g_alloca0()`
This commit is contained in:
Nishal Kulkarni 2021-11-25 13:44:23 +05:30 committed by Philip Withnall
parent 1c7936b368
commit 8bf62d6309

View File

@ -127,11 +127,9 @@ g_hmac_new (GChecksumType digest_type,
hmac->digesti = checksum;
hmac->digesto = g_checksum_new (digest_type);
buffer = g_alloca (block_size);
buffer = g_alloca0 (block_size);
pad = g_alloca (block_size);
memset (buffer, 0, block_size);
/* If the key is too long, hash it */
if (key_len > block_size)
{