diff options
author | Marc Horowitz <marc@mit.edu> | 1998-10-06 07:36:51 +0000 |
---|---|---|
committer | Marc Horowitz <marc@mit.edu> | 1998-10-06 07:36:51 +0000 |
commit | 506ad3d6dc6cee1e62b4e145f2cffd92740437b1 (patch) | |
tree | 1ecf81d9892dcace9694814617fbb5f4b4dc5c0a | |
parent | bc890a3f2004bacd7ce1567fb6edfb1ded5a9ef2 (diff) | |
download | krb5-506ad3d6dc6cee1e62b4e145f2cffd92740437b1.zip krb5-506ad3d6dc6cee1e62b4e145f2cffd92740437b1.tar.gz krb5-506ad3d6dc6cee1e62b4e145f2cffd92740437b1.tar.bz2 |
plug a memory leak
git-svn-id: svn://anonsvn.mit.edu/krb5/branches/marc-3des@10967 dc483132-0cff-0310-8789-dd5450dbe970
-rw-r--r-- | src/lib/krb5/krb/preauth.c | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/src/lib/krb5/krb/preauth.c b/src/lib/krb5/krb/preauth.c index 023a38e..ab1432f 100644 --- a/src/lib/krb5/krb/preauth.c +++ b/src/lib/krb5/krb/preauth.c @@ -160,6 +160,10 @@ krb5_error_code krb5_obtain_padata(context, preauth_to_use, key_proc, for (pa = preauth_to_use, size=0; *pa; pa++, size++) { if ((*pa)->pa_type == KRB5_PADATA_ETYPE_INFO) { + /* XXX use the first one. Is there another way to disambiguate? */ + if (etype_info) + continue; + scratch.length = (*pa)->length; scratch.data = (char *) (*pa)->contents; retval = decode_krb5_etype_info(&scratch, &etype_info); @@ -219,6 +223,8 @@ krb5_error_code krb5_obtain_padata(context, preauth_to_use, key_proc, } cleanup: + if (etype_info) + krb5_free_etype_info(context, etype_info); if (f_salt) krb5_xfree(salt.data); if (send_pa_list) |