aboutsummaryrefslogtreecommitdiff
path: root/src/util/crypto_hkdf.c
diff options
context:
space:
mode:
authorAlessio Vanni <vannilla@firemail.cc>2021-09-07 14:50:20 +0200
committerAlessio Vanni <vannilla@firemail.cc>2021-09-07 14:50:20 +0200
commit6e1bb6601e21a3329950129b9dc39e05746e3b65 (patch)
treedfc20058c8b430ef37c059ec21c2905168a07084 /src/util/crypto_hkdf.c
parent382fc8faaf4ccccd870dc7e746a9f002f3f6cfd1 (diff)
parent3da9cbd621a98c885a0c633ddaec0a84aa8a8e66 (diff)
downloadgnunet-6e1bb6601e21a3329950129b9dc39e05746e3b65.tar.gz
gnunet-6e1bb6601e21a3329950129b9dc39e05746e3b65.zip
-Merge branch 'master' into dev/vanni/build-info
Diffstat (limited to 'src/util/crypto_hkdf.c')
-rw-r--r--src/util/crypto_hkdf.c6
1 files changed, 5 insertions, 1 deletions
diff --git a/src/util/crypto_hkdf.c b/src/util/crypto_hkdf.c
index 86a814b12..7270b87b6 100644
--- a/src/util/crypto_hkdf.c
+++ b/src/util/crypto_hkdf.c
@@ -77,7 +77,11 @@ static const void *
77doHMAC (gcry_md_hd_t mac, const void *key, size_t key_len, const void *buf, 77doHMAC (gcry_md_hd_t mac, const void *key, size_t key_len, const void *buf,
78 size_t buf_len) 78 size_t buf_len)
79{ 79{
80 gcry_md_setkey (mac, key, key_len); 80 if (GPG_ERR_NO_ERROR != gcry_md_setkey (mac, key, key_len))
81 {
82 GNUNET_break (0);
83 return NULL;
84 }
81 gcry_md_write (mac, buf, buf_len); 85 gcry_md_write (mac, buf, buf_len);
82 86
83 return (const void *) gcry_md_read (mac, 0); 87 return (const void *) gcry_md_read (mac, 0);