From ecfde736ca1c196b2e69b621c7bd736908556050 Mon Sep 17 00:00:00 2001 From: Mark Eichin Date: Mon, 2 Oct 1995 19:33:06 +0000 Subject: [PATCH] * adm_conn.c (kadm_get_creds): zero out creds->server after freeing it to protect later attempts. git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@6920 dc483132-0cff-0310-8789-dd5450dbe970 --- src/lib/kadm/ChangeLog | 5 +++++ src/lib/kadm/adm_conn.c | 4 +++- 2 files changed, 8 insertions(+), 1 deletion(-) diff --git a/src/lib/kadm/ChangeLog b/src/lib/kadm/ChangeLog index 84e1fe997..5299d6a90 100644 --- a/src/lib/kadm/ChangeLog +++ b/src/lib/kadm/ChangeLog @@ -1,3 +1,8 @@ +Tue Sep 26 02:31:38 1995 Mark Eichin + + * adm_conn.c (kadm_get_creds): zero out creds->server after + freeing it to protect later attempts. + Fri Sep 29 17:06:18 1995 Theodore Y. Ts'o * logger.c: #ifdef the entire file so it's not built under Windows. diff --git a/src/lib/kadm/adm_conn.c b/src/lib/kadm/adm_conn.c index cb73e8aa2..3b737a087 100644 --- a/src/lib/kadm/adm_conn.c +++ b/src/lib/kadm/adm_conn.c @@ -283,8 +283,10 @@ kadm_get_creds(kcontext, ccache, client, creds, prompt, oldpw, tlife) cleanup: if (kret) { - if (creds->server) + if (creds->server) { krb5_free_principal(kcontext, creds->server); + creds->server = 0; + } } if (my_addresses) krb5_free_addresses(kcontext, my_addresses); -- 2.26.2