ldns/ldns-keygen-hmac-memory.patch

14 lines
390 B
Diff

Index: keys.c
===================================================================
--- keys.c (revision 2895)
+++ keys.c (revision 2897)
@@ -1050,7 +1050,7 @@
case LDNS_SIGN_HMACMD5:
case LDNS_SIGN_HMACSHA1:
case LDNS_SIGN_HMACSHA256:
- bin = LDNS_XMALLOC(unsigned char, size);
+ bin = LDNS_XMALLOC(unsigned char, ldns_key_hmac_size(k));
if (!bin) {
return NULL;
}