From: Greg Hudson Date: Fri, 30 Jan 2009 21:21:10 +0000 (+0000) Subject: In krb5_kdcrep2creds, call the correct free function when cleaning up X-Git-Tag: krb5-1.7-alpha1~15 X-Git-Url: http://git.tremily.us/?a=commitdiff_plain;h=cb834decad2d6dbe12549d20441b64e7e7e6672d;p=krb5.git In krb5_kdcrep2creds, call the correct free function when cleaning up the keyblock, and clean up the keyblock if krb5_copy_data fails. git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@21840 dc483132-0cff-0310-8789-dd5450dbe970 --- diff --git a/src/lib/krb5/krb/gc_via_tkt.c b/src/lib/krb5/krb/gc_via_tkt.c index 97e40bf3c..82972b7fc 100644 --- a/src/lib/krb5/krb/gc_via_tkt.c +++ b/src/lib/krb5/krb/gc_via_tkt.c @@ -55,7 +55,7 @@ krb5_kdcrep2creds(krb5_context context, krb5_kdc_rep *pkdcrep, krb5_address *con goto cleanup; if ((retval = krb5_copy_data(context, psectkt, &pdata))) - goto cleanup; + goto cleanup_keyblock; (*ppcreds)->second_ticket = *pdata; free(pdata); @@ -85,7 +85,7 @@ krb5_kdcrep2creds(krb5_context context, krb5_kdc_rep *pkdcrep, krb5_address *con return 0; cleanup_keyblock: - krb5_free_keyblock(context, &(*ppcreds)->keyblock); + krb5_free_keyblock_contents(context, &(*ppcreds)->keyblock); cleanup: free (*ppcreds);