From d97deb439175f77cc40f53156d78fc46d63aed36 Mon Sep 17 00:00:00 2001 From: Theodore Tso Date: Wed, 1 Dec 1993 22:24:15 +0000 Subject: [PATCH] Free cred->server before overwriting it git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@3058 dc483132-0cff-0310-8789-dd5450dbe970 --- src/lib/krb5/krb/gc_via_tgt.c | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/src/lib/krb5/krb/gc_via_tgt.c b/src/lib/krb5/krb/gc_via_tgt.c index 64d38d9b7..d6ef9119b 100644 --- a/src/lib/krb5/krb/gc_via_tgt.c +++ b/src/lib/krb5/krb/gc_via_tgt.c @@ -202,6 +202,10 @@ OLDDECLARG(krb5_creds *, cred) return retval; } } + /* + * Free cred->server before overwriting it. + */ + krb5_free_principal(cred->server); if (retval = krb5_copy_principal(dec_rep->enc_part2->server, &cred->server)) { cleanup(); -- 2.26.2