In k5_hmac_md5_hash_iov, initialize keyblock.contents so that we don't
authorGreg Hudson <ghudson@mit.edu>
Tue, 20 Oct 2009 13:49:48 +0000 (13:49 +0000)
committerGreg Hudson <ghudson@mit.edu>
Tue, 20 Oct 2009 13:49:48 +0000 (13:49 +0000)
free it prior to initialization if krb5_hmac fails.

git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@22953 dc483132-0cff-0310-8789-dd5450dbe970

src/lib/crypto/krb/keyhash_provider/hmac_md5.c

index 61c6d8c21df62ee656c47052edf36888de43e486..ad29d28498c46b475e62e54b505330fd31a81d96 100644 (file)
@@ -103,6 +103,8 @@ k5_hmac_md5_hash_iov (krb5_key key, krb5_keyusage usage,
   char t[4];
   size_t i;
 
+  keyblock.contents = NULL;
+
   ds.length = key->keyblock.length;
   ds.data = malloc(ds.length);
   if (ds.data == NULL)