mirror of
https://gitlab.gnome.org/GNOME/glib.git
synced 2024-12-26 15:36:14 +01:00
ghmac: Use new g_alloca0() function
Replace `g_alloca()` and `memset()` with `g_alloca0()`
This commit is contained in:
parent
1c7936b368
commit
8bf62d6309
@ -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)
|
||||
{
|
||||
|
Loading…
Reference in New Issue
Block a user